feat: add enchanter disciplines to unlock enchantment effects via perk progression
Build and Publish Mana Loop Docker Image / build-and-publish (push) Successful in 1m19s
Build and Publish Mana Loop Docker Image / build-and-publish (push) Successful in 1m19s
- Add unlocksEffects field to DisciplinePerk type - Add unlockEffects action to crafting store (deduplicating merge) - Modify discipline processTick to detect perk thresholds and return unlocked effect IDs - Wire gameStore tick to pass unlocked effects to crafting store - Create 8 new enchanter disciplines with tiered effect unlocks: Basic/Advanced Weapon, Utility, Mana, Basic/Intermediate/Advanced Spell, Special - Higher-tier disciplines require prerequisite disciplines - Add processedPerks tracking to prevent duplicate unlocks - Split enchanter disciplines into modular files (enchanter, enchanter-utility, enchanter-spells, enchanter-special) - All tests pass (784/784), no new TS errors, all files under 400 lines
This commit is contained in:
@@ -267,6 +267,14 @@ export const useGameStore = create<GameCoordinatorStore>()(
|
||||
rawMana = disciplineResult.rawMana;
|
||||
elements = disciplineResult.elements;
|
||||
|
||||
// Unlock enchantment effects from newly unlocked discipline perks
|
||||
if (disciplineResult.unlockedEffects.length > 0) {
|
||||
useCraftingStore.getState().unlockEffects(disciplineResult.unlockedEffects);
|
||||
for (const effectId of disciplineResult.unlockedEffects) {
|
||||
addLog(`✨ Discipline insight unlocked: ${effectId}`);
|
||||
}
|
||||
}
|
||||
|
||||
// Combat — delegate to combatStore
|
||||
if (ctx.combat.currentAction === 'climb') {
|
||||
const combatResult = useCombatStore.getState().processCombatTick(
|
||||
|
||||
Reference in New Issue
Block a user