diff --git a/client/src/components/Game/GameBoard.js b/client/src/components/Game/GameBoard.js index e42ace2..35df537 100644 --- a/client/src/components/Game/GameBoard.js +++ b/client/src/components/Game/GameBoard.js @@ -59,10 +59,18 @@ export default function GameBoard() { return (
-

SPLINTER

+ SPLINTER

Players:

- {state.players.map(player =>

{player}

)} + {state.players.map(player => { + return ( +
+

{player.name}

+

{player.points && `Score: ${player.points}`}

+
+ ) + }) + }
diff --git a/client/src/components/GameConfigForms/LocalMultiForm.js b/client/src/components/GameConfigForms/LocalMultiForm.js index b9644bf..b4561dd 100644 --- a/client/src/components/GameConfigForms/LocalMultiForm.js +++ b/client/src/components/GameConfigForms/LocalMultiForm.js @@ -58,7 +58,26 @@ export default function LocalMultiForm() { let toSubmit = []; let iter = 0; while (iter < players) { - toSubmit.push(allPlayerNames[iter]); + toSubmit.push({ + name: allPlayerNames[iter], + tokens: { + cedar: 0, + birch: 0, + walnut: 0, + mahogany: 0, + cherry: 0, + resin: 0, + }, + cards: { + cedar: 0, + birch: 0, + walnut: 0, + mahogany: 0, + cherry: 0, + }, + points: 0, + spirits: 0, + }); iter++; } diff --git a/client/src/store/Store.js b/client/src/store/Store.js index 8f4b674..346f735 100644 --- a/client/src/store/Store.js +++ b/client/src/store/Store.js @@ -6,7 +6,7 @@ import { TierThreeDeck } from './TierThreeDeck'; import { Spirits } from '../components/Game/Spirits'; const initialGameState = { - players: ['no players'], + players: [{name: 'no players', inventory: null, cards: null}], materials: { cards: { tierOneRemaining: TierOneDeck, diff --git a/client/src/styles/GameBoard.css b/client/src/styles/GameBoard.css index 469db5e..68e68da 100644 --- a/client/src/styles/GameBoard.css +++ b/client/src/styles/GameBoard.css @@ -1,4 +1,6 @@ .gameboard-title { + text-decoration: none; + font-size: 2rem; font-weight: bold; } diff --git a/package-lock.json b/package-lock.json new file mode 100644 index 0000000..e6d0f43 --- /dev/null +++ b/package-lock.json @@ -0,0 +1,27 @@ +{ + "name": "splinter", + "lockfileVersion": 2, + "requires": true, + "packages": { + "": { + "dependencies": { + "uuid": "^8.3.2" + } + }, + "node_modules/uuid": { + "version": "8.3.2", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-8.3.2.tgz", + "integrity": "sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==", + "bin": { + "uuid": "dist/bin/uuid" + } + } + }, + "dependencies": { + "uuid": { + "version": "8.3.2", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-8.3.2.tgz", + "integrity": "sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==" + } + } +} diff --git a/package.json b/package.json new file mode 100644 index 0000000..1456e6d --- /dev/null +++ b/package.json @@ -0,0 +1,5 @@ +{ + "dependencies": { + "uuid": "^8.3.2" + } +}