fix(pact-system): resolve 5 spec-vs-code discrepancies (DISC-4,6,8,11,12)
Build and Publish Mana Loop Docker Image / build-and-publish (push) Successful in 1m19s

- DISC-11: Fix floor 140/150 element composition in guardian-data.ts
  Floor 140 now uses [light, fire, radiantflames] (was [sand, earth, water])
  Floor 150 now uses [air, death, miasma] (was [lightning, fire, air])
- DISC-12: Reconcile spec §7.1 vs §8.2 tables in pact-system-spec.md
  Updated §8.2 to match §7.1 authoritative element mappings
- DISC-4: Deduplicate pact ritual completion logic
  Refactored pact-ritual.ts pipeline to delegate completion to
  prestigeStore.completePactRitual() instead of duplicating state writes
- DISC-6: Add 4 missing boon types to guardians
  critChance (floor 90), manaGain (floor 110), prestigeInsight (floor 200),
  studySpeed (floor 220) — all 12 spec boon types now used
- DISC-8: Add comment clarifying signedPactDetails persistence
  Code already correct (not reset by startNewLoop/resetPrestigeForNewLoop)
- Updated spire-utils.test.ts to match corrected floor 140/150 elements
This commit is contained in:
2026-06-08 22:50:03 +02:00
parent 573130cdb1
commit cba3090d7e
8 changed files with 43 additions and 65 deletions
+3 -2
View File
@@ -1,8 +1,9 @@
# Circular Dependencies
Generated: 2026-06-08T18:36:58.404Z
Found: 1 circular chain(s) — these MUST be fixed before modifying involved files.
Generated: 2026-06-08T20:08:33.456Z
Found: 2 circular chain(s) — these MUST be fixed before modifying involved files.
1. 1) stores/golem-combat-actions.ts > stores/golem-combat-helpers.ts
2. 2) stores/combatStore.ts > stores/combat-descent-actions.ts > stores/attunementStore.ts
## How to fix
1. Identify which import in the chain can be extracted to a shared types/utils file.
+2 -1
View File
@@ -1,6 +1,6 @@
{
"_meta": {
"generated": "2026-06-08T18:36:56.442Z",
"generated": "2026-06-08T20:08:31.411Z",
"description": "Import dependency graph for src/lib/game. Keys are files, values are arrays of files they import.",
"usage": "To find what a file affects, search for its path in the VALUES. To find what a file depends on, look at its KEY entry."
},
@@ -539,6 +539,7 @@
],
"stores/attunementStore.ts": [
"data/attunements.ts",
"stores/combatStore.ts",
"types.ts",
"utils/safe-persist.ts"
],
@@ -259,8 +259,8 @@ guardian's `unlocksMana` is derived from `resolveMultiUnlockChain(element)`:
| 110 | lightning | `fire`, `air`, `lightning` |
| 120 | frost | `air`, `water`, `frost` |
| 130 | blackflame | `fire`, `earth`, `metal` |
| 140 | radiantflames | `light`, `fire` |
| 150 | miasma | `air`, `death` |
| 140 | radiantflames | `light`, `fire`, `radiantflames` |
| 150 | miasma | `air`, `death`, `miasma` |
| 160 | shadowglass | `earth`, `dark` |
| 170+ | exotic | varies (see guardian-data.ts) |
@@ -298,8 +298,8 @@ mana to any elemental type. All elemental mana must come from:
| 110 | lightning | 22% | 13h |
| 120 | frost | 28% | 14h |
| 130 | blackflame | 32% | 15h |
| 140 | sand+earth+water | 25% | 16h |
| 150 | lightning+fire+air | 28% | 17h |
| 140 | light+fire+radiantflames | 25% | 16h |
| 150 | air+death+miasma | 28% | 17h |
| 160 | shadowglass | 33% | 18h |
### 8.3 Tier 3 — Exotic Elements (Floors 170240)