Fix Task 9: Climb/Descend Controls

1. Fixed exitSpireMode in store.ts to allow exit at any floor for re-entry resume
2. Removed floor restriction on Exit Spire button in page.tsx
3. Updated descend button label to use currentAction for 'Climbing' status
This commit is contained in:
Refactoring Agent
2026-04-29 10:39:11 +02:00
parent 351b6c2dca
commit c8a01acda3
2 changed files with 10 additions and 19 deletions
+2 -5
View File
@@ -2306,13 +2306,10 @@ export const useGameStore = create<GameStore>()(
}, 500);
},
// Exit Spire Mode - only works when at floor 1
// Exit Spire Mode - can exit at any floor (re-entry will resume at same floor)
exitSpireMode: () => {
set((state) => {
// Only allow exit if at floor 1 (bottom)
if (state.currentFloor > 1) {
return state; // Can't exit, need to climb down to floor 1 first
}
// Allow exit at any floor for re-entry resume
return {
spireMode: false,
currentAction: 'meditate',