fix: resolve 7 circular dependency chains in src/lib/game
Build and Publish Mana Loop Docker Image / build-and-publish (push) Failing after 57s

- equipment/utils.ts: import directly from individual equipment modules instead of index.ts
- golems/utils.ts: import directly from individual golem modules instead of index.ts
- combatStore.ts: extract CombatState to combat-state.types.ts, remove debugSetTime (was only user of gameStore import)
- combat-actions.ts: import CombatState from combat-state.types.ts instead of combatStore
- stores/index.ts: re-export CombatState from combat-state.types.ts
- GameStateDebug.tsx: replace debugSetTime calls with direct useGameStore.setState()

Verification: bunx madge --circular src/lib/game → No circular dependency found!
This commit is contained in:
2026-05-18 14:46:57 +02:00
parent ea3035ec5e
commit 084fea2a25
8 changed files with 148 additions and 115 deletions
+1 -1
View File
@@ -2,7 +2,7 @@
// Extracted combat logic from combatStore.ts
import { SPELLS_DEF, GUARDIANS, HOURS_PER_TICK } from '../constants';
import type { CombatState } from './combatStore';
import type { CombatState } from './combat-state.types';
import type { SpellState } from '../types';
import { getFloorMaxHP, getFloorElement, calcDamage, canAffordSpellCost, deductSpellCost } from '../utils';
import { usePrestigeStore } from './prestigeStore';