From b8babd592b60b1a2cfedac3956184207a3d4bb8d Mon Sep 17 00:00:00 2001 From: MikunoNaka Date: Sun, 1 Aug 2021 02:34:59 +0530 Subject: created menu entry to enter join code --- src/components/App.js | 3 +++ src/components/GamemodeChooser.js | 1 + src/components/MultiplayerGrid.js | 5 +++-- src/components/MultiplayerMenu.js | 45 ++++++++++++++++++++++++++++----------- 4 files changed, 40 insertions(+), 14 deletions(-) (limited to 'src/components') diff --git a/src/components/App.js b/src/components/App.js index db5af1b..5b13230 100644 --- a/src/components/App.js +++ b/src/components/App.js @@ -33,6 +33,7 @@ const App = () => { const [showMessageBox, setShowMessageBox] = useState(false); const [message, setMessage] = useState(""); const [isHost, setIsHost] = useState(false); + const [joinCode, setJoinCode] = useState(); return gameStarted ? ( <> @@ -61,6 +62,7 @@ const App = () => { setScoreO={setScoreO} setMessage={setMessage} setShowMessage={setShowMessageBox} + joinCode={joinCode} /> : { setMultiplayer={setMultiplayer} setGameStarted={setGameStarted} setIsHost={setIsHost} + setJoinCode={setJoinCode} />