feat: enable seamless game mode switching during active gameplay
- Remove quitGame() call from changeGameMode to allow continuous play - Game now transitions between modes without stopping - Add test case in example App to auto-switch from letters to words at score 10
This commit is contained in:
@@ -42,10 +42,7 @@ export function useGame(
|
||||
|
||||
const changeGameMode = (mode: GameMode) => {
|
||||
setGameModeState(mode);
|
||||
// Only quit if the game is actively running
|
||||
if (gameStatusManager.gameStatus === 'started') {
|
||||
gameStatusManager.quitGame();
|
||||
}
|
||||
// Don't quit - just switch modes and let game continue
|
||||
};
|
||||
|
||||
// Set the game loop callback
|
||||
|
||||
Reference in New Issue
Block a user