fix: implement fabricator attunement unlock condition (floor 20 guardian)
Build and Publish Mana Loop Docker Image / build-and-publish (push) Failing after 1m3s

This commit is contained in:
2026-06-10 23:01:32 +02:00
parent 05232ae03b
commit aa5d2abd68
5 changed files with 24 additions and 6 deletions
+2 -2
View File
@@ -88,8 +88,8 @@ export const useAttunementStore = create<AttunementStoreState>()(
// Invoker requires defeating the first guardian (floor 10)
if (!defeatedGuardians.includes(10)) return false;
} else if (attunementId === 'fabricator') {
// Fabricator: no specific gating condition implemented
return false;
// Fabricator requires defeating the second guardian (floor 20)
if (!defeatedGuardians.includes(20)) return false;
} else {
// Unknown attunement — don't unlock
return false;
@@ -130,6 +130,15 @@ export function buildCombatCallbacks(params: BuildCombatCallbacksParams) {
params.addLog('💜 The path of the Invoker is now available!');
}
}
// Auto-unlock Fabricator when the second guardian (floor 20) is defeated
if (floor === 20) {
const prestigeState = usePrestigeStore.getState();
const unlocked = useAttunementStore.getState().unlockAttunement('fabricator', prestigeState.defeatedGuardians);
if (unlocked) {
params.addLog('⚒️ The path of the Fabricator is now available!');
}
}
} else if (floor % 5 === 0) {
params.addLog('Floor ' + floor + ' cleared!');
}