thing is kind of broken
This commit is contained in:
122
client/package-lock.json
generated
122
client/package-lock.json
generated
@@ -10,9 +10,10 @@
|
|||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@testing-library/jest-dom": "^5.16.3",
|
"@testing-library/jest-dom": "^5.16.3",
|
||||||
"@testing-library/react": "^12.1.4",
|
"@testing-library/react": "^12.1.4",
|
||||||
|
"@testing-library/react-hooks": "^8.0.0",
|
||||||
"@testing-library/user-event": "^13.5.0",
|
"@testing-library/user-event": "^13.5.0",
|
||||||
"react": "^18.0.0",
|
"react": "^17.0.0",
|
||||||
"react-dom": "^18.0.0",
|
"react-dom": "^17.0.0",
|
||||||
"react-router-dom": "^6.2.2",
|
"react-router-dom": "^6.2.2",
|
||||||
"react-scripts": "5.0.0",
|
"react-scripts": "5.0.0",
|
||||||
"uuid": "^8.3.2",
|
"uuid": "^8.3.2",
|
||||||
@@ -3323,6 +3324,35 @@
|
|||||||
"react-dom": "*"
|
"react-dom": "*"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"node_modules/@testing-library/react-hooks": {
|
||||||
|
"version": "8.0.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/@testing-library/react-hooks/-/react-hooks-8.0.0.tgz",
|
||||||
|
"integrity": "sha512-uZqcgtcUUtw7Z9N32W13qQhVAD+Xki2hxbTR461MKax8T6Jr8nsUvZB+vcBTkzY2nFvsUet434CsgF0ncW2yFw==",
|
||||||
|
"dependencies": {
|
||||||
|
"@babel/runtime": "^7.12.5",
|
||||||
|
"react-error-boundary": "^3.1.0"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=12"
|
||||||
|
},
|
||||||
|
"peerDependencies": {
|
||||||
|
"@types/react": "^16.9.0 || ^17.0.0",
|
||||||
|
"react": "^16.9.0 || ^17.0.0",
|
||||||
|
"react-dom": "^16.9.0 || ^17.0.0",
|
||||||
|
"react-test-renderer": "^16.9.0 || ^17.0.0"
|
||||||
|
},
|
||||||
|
"peerDependenciesMeta": {
|
||||||
|
"@types/react": {
|
||||||
|
"optional": true
|
||||||
|
},
|
||||||
|
"react-dom": {
|
||||||
|
"optional": true
|
||||||
|
},
|
||||||
|
"react-test-renderer": {
|
||||||
|
"optional": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
"node_modules/@testing-library/user-event": {
|
"node_modules/@testing-library/user-event": {
|
||||||
"version": "13.5.0",
|
"version": "13.5.0",
|
||||||
"resolved": "https://registry.npmjs.org/@testing-library/user-event/-/user-event-13.5.0.tgz",
|
"resolved": "https://registry.npmjs.org/@testing-library/user-event/-/user-event-13.5.0.tgz",
|
||||||
@@ -13080,11 +13110,12 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/react": {
|
"node_modules/react": {
|
||||||
"version": "18.0.0",
|
"version": "17.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/react/-/react-18.0.0.tgz",
|
"resolved": "https://registry.npmjs.org/react/-/react-17.0.2.tgz",
|
||||||
"integrity": "sha512-x+VL6wbT4JRVPm7EGxXhZ8w8LTROaxPXOqhlGyVSrv0sB1jkyFGgXxJ8LVoPRLvPR6/CIZGFmfzqUa2NYeMr2A==",
|
"integrity": "sha512-gnhPt75i/dq/z3/6q/0asP78D0u592D5L1pd7M8P+dck6Fu/jJeL6iVVK23fptSUZj8Vjf++7wXA8UNclGQcbA==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"loose-envify": "^1.1.0"
|
"loose-envify": "^1.1.0",
|
||||||
|
"object-assign": "^4.1.1"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=0.10.0"
|
"node": ">=0.10.0"
|
||||||
@@ -13224,15 +13255,31 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/react-dom": {
|
"node_modules/react-dom": {
|
||||||
"version": "18.0.0",
|
"version": "17.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/react-dom/-/react-dom-18.0.0.tgz",
|
"resolved": "https://registry.npmjs.org/react-dom/-/react-dom-17.0.2.tgz",
|
||||||
"integrity": "sha512-XqX7uzmFo0pUceWFCt7Gff6IyIMzFUn7QMZrbrQfGxtaxXZIcGQzoNpRLE3fQLnS4XzLLPMZX2T9TRcSrasicw==",
|
"integrity": "sha512-s4h96KtLDUQlsENhMn1ar8t2bEa+q/YAtj8pPPdIjPDGBDIVNsrD9aXNWqspUe6AzKCIG0C1HZZLqLV7qpOBGA==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"loose-envify": "^1.1.0",
|
"loose-envify": "^1.1.0",
|
||||||
"scheduler": "^0.21.0"
|
"object-assign": "^4.1.1",
|
||||||
|
"scheduler": "^0.20.2"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"react": "^18.0.0"
|
"react": "17.0.2"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"node_modules/react-error-boundary": {
|
||||||
|
"version": "3.1.4",
|
||||||
|
"resolved": "https://registry.npmjs.org/react-error-boundary/-/react-error-boundary-3.1.4.tgz",
|
||||||
|
"integrity": "sha512-uM9uPzZJTF6wRQORmSrvOIgt4lJ9MC1sNgEOj2XGsDTRE4kmpWxg7ENK9EWNKJRMAOY9z0MuF4yIfl6gp4sotA==",
|
||||||
|
"dependencies": {
|
||||||
|
"@babel/runtime": "^7.12.5"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=10",
|
||||||
|
"npm": ">=6"
|
||||||
|
},
|
||||||
|
"peerDependencies": {
|
||||||
|
"react": ">=16.13.1"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/react-error-overlay": {
|
"node_modules/react-error-overlay": {
|
||||||
@@ -13837,11 +13884,12 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/scheduler": {
|
"node_modules/scheduler": {
|
||||||
"version": "0.21.0",
|
"version": "0.20.2",
|
||||||
"resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.21.0.tgz",
|
"resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.20.2.tgz",
|
||||||
"integrity": "sha512-1r87x5fz9MXqswA2ERLo0EbOAU74DpIUO090gIasYTqlVoJeMcl+Z1Rg7WHz+qtPujhS/hGIt9kxZOYBV3faRQ==",
|
"integrity": "sha512-2eWfGgAqqWFGqtdMmcL5zCMK1U8KlXv8SQFGglL3CEtd0aDVDWgeF/YoCmvln55m5zSk3J/20hTaSBeSObsQDQ==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"loose-envify": "^1.1.0"
|
"loose-envify": "^1.1.0",
|
||||||
|
"object-assign": "^4.1.1"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/schema-utils": {
|
"node_modules/schema-utils": {
|
||||||
@@ -18365,6 +18413,15 @@
|
|||||||
"@types/react-dom": "*"
|
"@types/react-dom": "*"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"@testing-library/react-hooks": {
|
||||||
|
"version": "8.0.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/@testing-library/react-hooks/-/react-hooks-8.0.0.tgz",
|
||||||
|
"integrity": "sha512-uZqcgtcUUtw7Z9N32W13qQhVAD+Xki2hxbTR461MKax8T6Jr8nsUvZB+vcBTkzY2nFvsUet434CsgF0ncW2yFw==",
|
||||||
|
"requires": {
|
||||||
|
"@babel/runtime": "^7.12.5",
|
||||||
|
"react-error-boundary": "^3.1.0"
|
||||||
|
}
|
||||||
|
},
|
||||||
"@testing-library/user-event": {
|
"@testing-library/user-event": {
|
||||||
"version": "13.5.0",
|
"version": "13.5.0",
|
||||||
"resolved": "https://registry.npmjs.org/@testing-library/user-event/-/user-event-13.5.0.tgz",
|
"resolved": "https://registry.npmjs.org/@testing-library/user-event/-/user-event-13.5.0.tgz",
|
||||||
@@ -25365,11 +25422,12 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"react": {
|
"react": {
|
||||||
"version": "18.0.0",
|
"version": "17.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/react/-/react-18.0.0.tgz",
|
"resolved": "https://registry.npmjs.org/react/-/react-17.0.2.tgz",
|
||||||
"integrity": "sha512-x+VL6wbT4JRVPm7EGxXhZ8w8LTROaxPXOqhlGyVSrv0sB1jkyFGgXxJ8LVoPRLvPR6/CIZGFmfzqUa2NYeMr2A==",
|
"integrity": "sha512-gnhPt75i/dq/z3/6q/0asP78D0u592D5L1pd7M8P+dck6Fu/jJeL6iVVK23fptSUZj8Vjf++7wXA8UNclGQcbA==",
|
||||||
"requires": {
|
"requires": {
|
||||||
"loose-envify": "^1.1.0"
|
"loose-envify": "^1.1.0",
|
||||||
|
"object-assign": "^4.1.1"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"react-app-polyfill": {
|
"react-app-polyfill": {
|
||||||
@@ -25472,12 +25530,21 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"react-dom": {
|
"react-dom": {
|
||||||
"version": "18.0.0",
|
"version": "17.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/react-dom/-/react-dom-18.0.0.tgz",
|
"resolved": "https://registry.npmjs.org/react-dom/-/react-dom-17.0.2.tgz",
|
||||||
"integrity": "sha512-XqX7uzmFo0pUceWFCt7Gff6IyIMzFUn7QMZrbrQfGxtaxXZIcGQzoNpRLE3fQLnS4XzLLPMZX2T9TRcSrasicw==",
|
"integrity": "sha512-s4h96KtLDUQlsENhMn1ar8t2bEa+q/YAtj8pPPdIjPDGBDIVNsrD9aXNWqspUe6AzKCIG0C1HZZLqLV7qpOBGA==",
|
||||||
"requires": {
|
"requires": {
|
||||||
"loose-envify": "^1.1.0",
|
"loose-envify": "^1.1.0",
|
||||||
"scheduler": "^0.21.0"
|
"object-assign": "^4.1.1",
|
||||||
|
"scheduler": "^0.20.2"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"react-error-boundary": {
|
||||||
|
"version": "3.1.4",
|
||||||
|
"resolved": "https://registry.npmjs.org/react-error-boundary/-/react-error-boundary-3.1.4.tgz",
|
||||||
|
"integrity": "sha512-uM9uPzZJTF6wRQORmSrvOIgt4lJ9MC1sNgEOj2XGsDTRE4kmpWxg7ENK9EWNKJRMAOY9z0MuF4yIfl6gp4sotA==",
|
||||||
|
"requires": {
|
||||||
|
"@babel/runtime": "^7.12.5"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"react-error-overlay": {
|
"react-error-overlay": {
|
||||||
@@ -25899,11 +25966,12 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"scheduler": {
|
"scheduler": {
|
||||||
"version": "0.21.0",
|
"version": "0.20.2",
|
||||||
"resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.21.0.tgz",
|
"resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.20.2.tgz",
|
||||||
"integrity": "sha512-1r87x5fz9MXqswA2ERLo0EbOAU74DpIUO090gIasYTqlVoJeMcl+Z1Rg7WHz+qtPujhS/hGIt9kxZOYBV3faRQ==",
|
"integrity": "sha512-2eWfGgAqqWFGqtdMmcL5zCMK1U8KlXv8SQFGglL3CEtd0aDVDWgeF/YoCmvln55m5zSk3J/20hTaSBeSObsQDQ==",
|
||||||
"requires": {
|
"requires": {
|
||||||
"loose-envify": "^1.1.0"
|
"loose-envify": "^1.1.0",
|
||||||
|
"object-assign": "^4.1.1"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"schema-utils": {
|
"schema-utils": {
|
||||||
|
|||||||
@@ -5,9 +5,10 @@
|
|||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@testing-library/jest-dom": "^5.16.3",
|
"@testing-library/jest-dom": "^5.16.3",
|
||||||
"@testing-library/react": "^12.1.4",
|
"@testing-library/react": "^12.1.4",
|
||||||
|
"@testing-library/react-hooks": "^8.0.0",
|
||||||
"@testing-library/user-event": "^13.5.0",
|
"@testing-library/user-event": "^13.5.0",
|
||||||
"react": "^18.0.0",
|
"react": "^17.0.0",
|
||||||
"react-dom": "^18.0.0",
|
"react-dom": "^17.0.0",
|
||||||
"react-router-dom": "^6.2.2",
|
"react-router-dom": "^6.2.2",
|
||||||
"react-scripts": "5.0.0",
|
"react-scripts": "5.0.0",
|
||||||
"uuid": "^8.3.2",
|
"uuid": "^8.3.2",
|
||||||
|
|||||||
@@ -1,4 +1,6 @@
|
|||||||
.App {
|
.App {
|
||||||
|
background-color: purple;
|
||||||
|
height: 100vh;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
|
|||||||
@@ -85,7 +85,9 @@ export default function GameBoard() {
|
|||||||
{tierOne || 'Loading'}
|
{tierOne || 'Loading'}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<h2>Deck length: {TierOneDeck.length}</h2>
|
<h2>Tier one length: {TierOneDeck.length} / 40</h2>
|
||||||
|
<h2>Tier two length: {TierTwoDeck.length} / 30</h2>
|
||||||
|
<h2>Tier three length: {TierThreeDeck.length} / 20</h2>
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
@@ -62,7 +62,7 @@ export default function LocalMultiForm() {
|
|||||||
name: allPlayerNames[iter],
|
name: allPlayerNames[iter],
|
||||||
tokens: {
|
tokens: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 0,
|
cherry: 0,
|
||||||
@@ -70,7 +70,7 @@ export default function LocalMultiForm() {
|
|||||||
},
|
},
|
||||||
cards: {
|
cards: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 0,
|
cherry: 0,
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ export const Spirits = [
|
|||||||
img: 'img src',
|
img: 'img src',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 7,
|
cedar: 7,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -13,7 +13,7 @@ export const Spirits = [
|
|||||||
img: 'img src',
|
img: 'img src',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 7,
|
cedar: 7,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -23,7 +23,7 @@ export const Spirits = [
|
|||||||
img: 'img src',
|
img: 'img src',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 7,
|
cedar: 7,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -33,7 +33,7 @@ export const Spirits = [
|
|||||||
img: 'img src',
|
img: 'img src',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 7,
|
cedar: 7,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -43,7 +43,7 @@ export const Spirits = [
|
|||||||
img: 'img src',
|
img: 'img src',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 7,
|
cedar: 7,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -3,7 +3,7 @@ import { useReducer, createContext } from "react"
|
|||||||
import { TierOneDeck } from './TierOneDeck';
|
import { TierOneDeck } from './TierOneDeck';
|
||||||
import { TierTwoDeck } from './TierTwoDeck';
|
import { TierTwoDeck } from './TierTwoDeck';
|
||||||
import { TierThreeDeck } from './TierThreeDeck';
|
import { TierThreeDeck } from './TierThreeDeck';
|
||||||
import { Spirits } from '../components/Game/Spirits';
|
import { Spirits } from './Spirits';
|
||||||
|
|
||||||
const initialGameState = {
|
const initialGameState = {
|
||||||
players: [{name: 'no players', inventory: null, cards: null}],
|
players: [{name: 'no players', inventory: null, cards: null}],
|
||||||
@@ -15,7 +15,7 @@ const initialGameState = {
|
|||||||
},
|
},
|
||||||
tokens: {
|
tokens: {
|
||||||
cedar: 7,
|
cedar: 7,
|
||||||
birch: 7,
|
aspen: 7,
|
||||||
walnut: 7,
|
walnut: 7,
|
||||||
mahogany: 7,
|
mahogany: 7,
|
||||||
cherry: 7,
|
cherry: 7,
|
||||||
|
|||||||
@@ -2,39 +2,15 @@ export const TierOneDeck = [
|
|||||||
// TIER ONE CARDS
|
// TIER ONE CARDS
|
||||||
// total: 40
|
// total: 40
|
||||||
// cat 1: [2,1] cost cards
|
// cat 1: [2,1] cost cards
|
||||||
{
|
|
||||||
tier: 1,
|
|
||||||
points: 0,
|
|
||||||
isWorth: 'cedar',
|
|
||||||
cost: {
|
|
||||||
cedar: 2,
|
|
||||||
birch: 1,
|
|
||||||
walnut: 0,
|
|
||||||
mahogany: 0,
|
|
||||||
cherry: 0
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
tier: 1,
|
|
||||||
points: 0,
|
|
||||||
isWorth: 'birch',
|
|
||||||
cost: {
|
|
||||||
cedar: 0,
|
|
||||||
birch: 2,
|
|
||||||
walnut: 1,
|
|
||||||
mahogany: 0,
|
|
||||||
cherry: 0
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
tier: 1,
|
tier: 1,
|
||||||
points: 0,
|
points: 0,
|
||||||
isWorth: 'walnut',
|
isWorth: 'walnut',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 0,
|
cedar: 2,
|
||||||
birch: 0,
|
aspen: 1,
|
||||||
walnut: 2,
|
walnut: 0,
|
||||||
mahogany: 1,
|
mahogany: 0,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -44,7 +20,31 @@ export const TierOneDeck = [
|
|||||||
isWorth: 'mahogany',
|
isWorth: 'mahogany',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 0,
|
aspen: 2,
|
||||||
|
walnut: 1,
|
||||||
|
mahogany: 0,
|
||||||
|
cherry: 0
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
tier: 1,
|
||||||
|
points: 0,
|
||||||
|
isWorth: 'cherry',
|
||||||
|
cost: {
|
||||||
|
cedar: 0,
|
||||||
|
aspen: 0,
|
||||||
|
walnut: 2,
|
||||||
|
mahogany: 1,
|
||||||
|
cherry: 0
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
tier: 1,
|
||||||
|
points: 0,
|
||||||
|
isWorth: 'cedar',
|
||||||
|
cost: {
|
||||||
|
cedar: 0,
|
||||||
|
aspen: 0,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 2,
|
mahogany: 2,
|
||||||
cherry: 1
|
cherry: 1
|
||||||
@@ -53,10 +53,10 @@ export const TierOneDeck = [
|
|||||||
{
|
{
|
||||||
tier: 1,
|
tier: 1,
|
||||||
points: 0,
|
points: 0,
|
||||||
isWorth: 'cherry',
|
isWorth: 'aspen',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 1,
|
cedar: 1,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 2
|
cherry: 2
|
||||||
@@ -70,7 +70,7 @@ export const TierOneDeck = [
|
|||||||
isWorth: 'cedar',
|
isWorth: 'cedar',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 3,
|
cedar: 3,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -79,10 +79,10 @@ export const TierOneDeck = [
|
|||||||
{
|
{
|
||||||
tier: 1,
|
tier: 1,
|
||||||
points: 0,
|
points: 0,
|
||||||
isWorth: 'birch',
|
isWorth: 'aspen',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 3,
|
aspen: 3,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -94,7 +94,7 @@ export const TierOneDeck = [
|
|||||||
isWorth: 'walnut',
|
isWorth: 'walnut',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 3,
|
walnut: 3,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -106,7 +106,7 @@ export const TierOneDeck = [
|
|||||||
isWorth: 'mahogany',
|
isWorth: 'mahogany',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 3,
|
mahogany: 3,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -118,7 +118,7 @@ export const TierOneDeck = [
|
|||||||
isWorth: 'cherry',
|
isWorth: 'cherry',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 3
|
cherry: 3
|
||||||
@@ -132,7 +132,7 @@ export const TierOneDeck = [
|
|||||||
isWorth: 'cedar',
|
isWorth: 'cedar',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 4,
|
cedar: 4,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -141,10 +141,10 @@ export const TierOneDeck = [
|
|||||||
{
|
{
|
||||||
tier: 1,
|
tier: 1,
|
||||||
points: 1,
|
points: 1,
|
||||||
isWorth: 'birch',
|
isWorth: 'aspen',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 4,
|
aspen: 4,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -156,7 +156,7 @@ export const TierOneDeck = [
|
|||||||
isWorth: 'walnut',
|
isWorth: 'walnut',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 4,
|
walnut: 4,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -168,7 +168,7 @@ export const TierOneDeck = [
|
|||||||
isWorth: 'mahogany',
|
isWorth: 'mahogany',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 4,
|
mahogany: 4,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -180,7 +180,7 @@ export const TierOneDeck = [
|
|||||||
isWorth: 'cherry',
|
isWorth: 'cherry',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 4
|
cherry: 4
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ export const TierThreeDeck = [
|
|||||||
isWorth: 'cedar',
|
isWorth: 'cedar',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 7,
|
cedar: 7,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -17,10 +17,10 @@ export const TierThreeDeck = [
|
|||||||
{
|
{
|
||||||
tier: 3,
|
tier: 3,
|
||||||
points: 5,
|
points: 5,
|
||||||
isWorth: 'birch',
|
isWorth: 'aspen',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 7,
|
aspen: 7,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -32,7 +32,7 @@ export const TierThreeDeck = [
|
|||||||
isWorth: 'walnut',
|
isWorth: 'walnut',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 7,
|
walnut: 7,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -44,7 +44,7 @@ export const TierThreeDeck = [
|
|||||||
isWorth: 'mahogany',
|
isWorth: 'mahogany',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 7,
|
mahogany: 7,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -56,7 +56,7 @@ export const TierThreeDeck = [
|
|||||||
isWorth: 'cherry',
|
isWorth: 'cherry',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 7
|
cherry: 7
|
||||||
@@ -70,7 +70,7 @@ export const TierThreeDeck = [
|
|||||||
isWorth: 'cedar',
|
isWorth: 'cedar',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 7,
|
cedar: 7,
|
||||||
birch: 3,
|
aspen: 3,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -79,10 +79,10 @@ export const TierThreeDeck = [
|
|||||||
{
|
{
|
||||||
tier: 2,
|
tier: 2,
|
||||||
points: 5,
|
points: 5,
|
||||||
isWorth: 'birch',
|
isWorth: 'aspen',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 7,
|
aspen: 7,
|
||||||
walnut: 3,
|
walnut: 3,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -94,7 +94,7 @@ export const TierThreeDeck = [
|
|||||||
isWorth: 'walnut',
|
isWorth: 'walnut',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 7,
|
walnut: 7,
|
||||||
mahogany: 3,
|
mahogany: 3,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -106,7 +106,7 @@ export const TierThreeDeck = [
|
|||||||
isWorth: 'mahogany',
|
isWorth: 'mahogany',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 7,
|
mahogany: 7,
|
||||||
cherry: 3
|
cherry: 3
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ export const TierTwoDeck = [
|
|||||||
isWorth: 'cedar',
|
isWorth: 'cedar',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 5,
|
cedar: 5,
|
||||||
birch: 3,
|
aspen: 3,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -17,10 +17,10 @@ export const TierTwoDeck = [
|
|||||||
{
|
{
|
||||||
tier: 2,
|
tier: 2,
|
||||||
points: 3,
|
points: 3,
|
||||||
isWorth: 'birch',
|
isWorth: 'aspen',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 5,
|
aspen: 5,
|
||||||
walnut: 3,
|
walnut: 3,
|
||||||
mahogany: 0,
|
mahogany: 0,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -32,7 +32,7 @@ export const TierTwoDeck = [
|
|||||||
isWorth: 'walnut',
|
isWorth: 'walnut',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 5,
|
walnut: 5,
|
||||||
mahogany: 3,
|
mahogany: 3,
|
||||||
cherry: 0
|
cherry: 0
|
||||||
@@ -44,7 +44,7 @@ export const TierTwoDeck = [
|
|||||||
isWorth: 'mahogany',
|
isWorth: 'mahogany',
|
||||||
cost: {
|
cost: {
|
||||||
cedar: 0,
|
cedar: 0,
|
||||||
birch: 0,
|
aspen: 0,
|
||||||
walnut: 0,
|
walnut: 0,
|
||||||
mahogany: 5,
|
mahogany: 5,
|
||||||
cherry: 3
|
cherry: 3
|
||||||
|
|||||||
76
client/src/store/allCards.js
Normal file
76
client/src/store/allCards.js
Normal file
@@ -0,0 +1,76 @@
|
|||||||
|
const allCards = [
|
||||||
|
{
|
||||||
|
tier: 1,
|
||||||
|
points: 0,
|
||||||
|
isWorth: 'cedar',
|
||||||
|
cost: {
|
||||||
|
cedar: 3,
|
||||||
|
aspen: 0,
|
||||||
|
walnut: 0,
|
||||||
|
mahogany: 0,
|
||||||
|
cherry: 0
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
tier: 1,
|
||||||
|
points: 0,
|
||||||
|
isWorth: 'aspen',
|
||||||
|
cost: {
|
||||||
|
cedar: 0,
|
||||||
|
aspen: 3,
|
||||||
|
walnut: 0,
|
||||||
|
mahogany: 0,
|
||||||
|
cherry: 0
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
tier: 1,
|
||||||
|
points: 0,
|
||||||
|
isWorth: 'walnut',
|
||||||
|
cost: {
|
||||||
|
cedar: 0,
|
||||||
|
aspen: 0,
|
||||||
|
walnut: 3,
|
||||||
|
mahogany: 0,
|
||||||
|
cherry: 0
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
tier: 1,
|
||||||
|
points: 0,
|
||||||
|
isWorth: 'mahogany',
|
||||||
|
cost: {
|
||||||
|
cedar: 0,
|
||||||
|
aspen: 0,
|
||||||
|
walnut: 0,
|
||||||
|
mahogany: 3,
|
||||||
|
cherry: 0
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
tier: 1,
|
||||||
|
points: 0,
|
||||||
|
isWorth: 'cherry',
|
||||||
|
cost: {
|
||||||
|
cedar: 0,
|
||||||
|
aspen: 0,
|
||||||
|
walnut: 0,
|
||||||
|
mahogany: 0,
|
||||||
|
cherry: 3
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
tier: 1,
|
||||||
|
points: 0,
|
||||||
|
isWorth: 'cedar',
|
||||||
|
cost: {
|
||||||
|
cedar: 3,
|
||||||
|
aspen: 0,
|
||||||
|
walnut: 0,
|
||||||
|
mahogany: 0,
|
||||||
|
cherry: 0
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
|
||||||
|
module.exports = allCards;
|
||||||
15
client/src/store/quickref.txt
Normal file
15
client/src/store/quickref.txt
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
cedar = emerald
|
||||||
|
aspen = diamond
|
||||||
|
cherry = ruby
|
||||||
|
walnut = sapphire
|
||||||
|
mahogany = onyx
|
||||||
|
resin = gold
|
||||||
|
|
||||||
|
|
||||||
|
tokens => card worth
|
||||||
|
aspen (diamond) => cherry (ruby)
|
||||||
|
walnut (sapphire) => mahogany (onyx)
|
||||||
|
cedar (emerald) => aspen (diamond)
|
||||||
|
mahogany (onyx) => cedar (emerald)
|
||||||
|
cherry (ruby) => walnut (sapphire)
|
||||||
|
|
||||||
14
client/src/tests/CardDecks.test.js
Normal file
14
client/src/tests/CardDecks.test.js
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
import { Context } from '../store/Store';
|
||||||
|
import { render, screen } from '@testing-library/react';
|
||||||
|
import { renderHook } from '@testing-library/react-hooks';
|
||||||
|
import { useContext } from 'react';
|
||||||
|
|
||||||
|
describe('card deck', () => {
|
||||||
|
describe('tier one deck', () => {
|
||||||
|
it('has 30 cards', () => {
|
||||||
|
const { theThing } = renderHook(useContext(Context));
|
||||||
|
let expected = 30;
|
||||||
|
expect(expected).toBe(30);
|
||||||
|
})
|
||||||
|
})
|
||||||
|
})
|
||||||
Reference in New Issue
Block a user