[Medium] [Bug] Mana conversion: spec substantially implemented, but discipline pool-drain model still coexists with new regen-deduction system #334
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Spec:
docs/specs/mana-conversion-spec.mdStatus: The new unified conversion system is substantially implemented — all core files exist, formulas match, and the tick pipeline uses the regen deduction model. The discrepancies below are remaining gaps.
DISC-2 [MEDIUM] — Discipline
processTick()still drains mana from pools via old modelsrc/lib/game/stores/discipline-slice.ts→processTick()calculateManaDrain()and deducts directly fromrawManaandelements[manaType].currentprocessTick().DISC-4 [MEDIUM] — Crafting pipeline may still have composite crafting logic
src/lib/game/crafting-fabricator.ts,src/lib/game/crafting-design.tscraftCompositewas removed frommanaStore.tsbut composite crafting logic in the crafting pipeline was not fully auditedcraftCompositeor manual composite crafting logic and remove/replace with passive conversionDISC-5 [LOW] — No collapsible formula reference in Stats tab
ElementStatsSection.tsxhas no formula referenceDISC-6 [LOW] — No per-element net regen summary line in Stats tab
ConversionRowshows downstream drain but doesn't compute a single net regen summaryDISC-7 [LOW] — Conversion stats not in dedicated section
ElementStatsSectionunder "Conversion Breakdown"DISC-8 [LOW] — ManaDisplay shows only net regen, not detailed breakdown
ManaDisplay.tsx): Only shows net regen rate per elementWhat IS implemented correctly (for reference):
element-distance.ts— distance table ✅conversion-costs.ts— cost ratios ✅conversion-rates.ts— unified formula ✅Starting work on issue #334. Will address all 8 sub-items (DISC-2 through DISC-8). First reading the spec and relevant source files.
All 8 sub-items of issue #334 have been addressed and committed (
3ad919a):DISC-2 [MEDIUM] ✅ — Removed old pool-drain model from discipline-slice.ts processTick()
DISC-4 [MEDIUM] ✅ — Crafting pipeline audit complete
DISC-5 [LOW] ✅ — Added collapsible formula reference to Conversion Stats section
DISC-6 [LOW] ✅ — Added per-element net regen summary line
DISC-7 [LOW] ✅ — Created dedicated "Conversion Stats" section in Stats tab
DISC-8 [LOW] ✅ — Added detailed per-element regen breakdown to ManaDisplay
Tests: Updated 4 test files to reflect new no-drain behavior. All 1090 tests pass.
Pre-commit: All checks passed (file sizes, tests, dependency graph).