PR: refactor state game

This commit is contained in:
math-pixel
2026-05-12 13:47:05 +02:00
parent eab552a09b
commit 8d197ba26b
6 changed files with 17 additions and 17 deletions
+3 -3
View File
@@ -26,8 +26,8 @@ export function ZoneDetection(): null {
const camera = useThree((state) => state.camera);
const triggeredZones = useRef<Set<string>>(new Set());
const debug = Debug.getInstance();
const step = useGameStore((state) => state.missionFlow.step);
const setStep = useGameStore((state) => state.setFlowStep);
const step = useGameStore((state) => state.intro.currentStep);
const setStep = useGameStore((state) => state.setIntroStep);
useEffect(() => {
if (!debug.active) return;
@@ -45,7 +45,7 @@ export function ZoneDetection(): null {
folder.add(playerPos, "z").name("Player Z").listen().disable();
const unsubStore = useGameStore.subscribe((state) => {
gameState.step = state.missionFlow.step;
gameState.step = state.intro.currentStep;
folder.controllersRecursive().forEach((c) => c.updateDisplay());
});