Simplify custom world result editing controls
This commit is contained in:
11
src/App.tsx
11
src/App.tsx
@@ -20,7 +20,7 @@ export default function App() {
|
||||
isMapOpen,
|
||||
setIsMapOpen,
|
||||
resetGame,
|
||||
handleWorldSelect: selectWorld,
|
||||
handleCustomWorldSelect: selectCustomWorld,
|
||||
handleBackToWorldSelect: backToWorldSelect,
|
||||
handleCharacterSelect: selectCharacter,
|
||||
} = useGameFlow();
|
||||
@@ -73,12 +73,11 @@ export default function App() {
|
||||
return () => window.clearInterval(intervalId);
|
||||
}, [gameState.currentScene, gameState.playerCharacter, setGameState]);
|
||||
|
||||
const handleWorldSelect = (
|
||||
worldType: Parameters<typeof selectWorld>[0],
|
||||
customWorldProfile?: Parameters<typeof selectWorld>[1],
|
||||
const handleCustomWorldSelect = (
|
||||
customWorldProfile: Parameters<typeof selectCustomWorld>[0],
|
||||
) => {
|
||||
storyFlow.resetStoryState();
|
||||
selectWorld(worldType, customWorldProfile);
|
||||
selectCustomWorld(customWorldProfile);
|
||||
};
|
||||
|
||||
const handleCharacterSelect = (
|
||||
@@ -152,7 +151,7 @@ export default function App() {
|
||||
handleContinueGame,
|
||||
handleStartNewGame,
|
||||
handleSaveAndExit,
|
||||
handleWorldSelect,
|
||||
handleCustomWorldSelect,
|
||||
handleBackToWorldSelect,
|
||||
handleCharacterSelect,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user