fix(#165,#166,#167,#168,#169,#171,#172): resolve 7 open bug issues
#172 - Grimoire tab: removed dead 'loaded' state guard that permanently showed loading #169 - Transference Mana Flow: added elements param to checkDisciplinePrerequisites so mana type unlocks are verified #168 - Perk descriptions: wired 4 broken perks (enchant-2, channel-1, golem-2, efficiency-1) with actual bonus effects; fixed enchant-1 interval (5→50); fixed study-mana-enchantments stat (maxMana→maxManaBonus) #171 - Shields: removed all shield equipment (4 types), recipes, category, slot mappings; added 'shields' to AGENTS.md banned list #166 - regenMultiplier: merged disciplineEffects.multipliers.regenMultiplier into computeAllEffects() #165 - Meditation cap: added meditationCap display to ManaStatsSection UI; updated perk description #167 - XP accumulation: added Meditative Mastery base discipline with disciplineXpBonus stat; wired into tick pipeline
This commit is contained in:
@@ -10,6 +10,7 @@ import {
|
||||
checkDisciplinePrerequisites,
|
||||
getUnlockedPerks
|
||||
} from '../utils/discipline-math';
|
||||
import { computeDisciplineEffects } from '../effects/discipline-effects';
|
||||
import { baseDisciplines } from '../data/disciplines/base';
|
||||
import { elementalAttunementDisciplines } from '../data/disciplines/elemental';
|
||||
import { elementalRegenDisciplines } from '../data/disciplines/elemental-regen';
|
||||
@@ -99,8 +100,8 @@ export const useDisciplineStore = create<DisciplineStore>()(
|
||||
if (signedPacts.length === 0) return s;
|
||||
}
|
||||
|
||||
// Check discipline prerequisites (requires field → discipline XP)
|
||||
const prereqCheck = checkDisciplinePrerequisites(def, s.disciplines, ALL_DISCIPLINES);
|
||||
// Check discipline prerequisites (requires field → discipline XP or mana type unlock)
|
||||
const prereqCheck = checkDisciplinePrerequisites(def, s.disciplines, ALL_DISCIPLINES, gameState?.elements);
|
||||
if (!prereqCheck.canProceed) return s;
|
||||
|
||||
// For conversion disciplines: gate on having all source mana types unlocked
|
||||
@@ -183,8 +184,10 @@ export const useDisciplineStore = create<DisciplineStore>()(
|
||||
}
|
||||
|
||||
const oldXP = disc.xp;
|
||||
newDisciplines[id] = { ...disc, xp: disc.xp + 1 };
|
||||
newXP += 1;
|
||||
const xpBonus = computeDisciplineEffects().bonuses.disciplineXpBonus || 0;
|
||||
const xpGain = 1 + xpBonus;
|
||||
newDisciplines[id] = { ...disc, xp: disc.xp + xpGain };
|
||||
newXP += xpGain;
|
||||
|
||||
// Check for newly unlocked perks that unlock effects
|
||||
if (def.perks.length > 0) {
|
||||
|
||||
Reference in New Issue
Block a user