How redward42/theyreatenbut works
This is a single-page React guessing game: the player starts a round, guesses a team member’s rating for a scenario, sees feedback, and can continue or reset. The central game component manages screen state and round selection; question and roster JSON provide the game data. The README documents sampling without replacement, while the excerpt shows the component’s bag logic and its optional sound and confetti effects. Source excerpts are partial, so the graph omits unverified details such as the specific photo-loading mechanism.
Main entry points: TheyreATenGame.tsx Game controller · main.tsx React bootstrap · App.tsx App wrapper · questions.json Question ratings
Components 14
App entry
- React bootstrap
src/main.tsx - App wrapper
src/App.tsx
Game flow
- Game controller
src/components/TheyreATenGame.tsx - Start screen
src/components/TheyreATenGame.tsx - Round sampling
src/components/TheyreATenGame.tsx - Question screen
src/components/TheyreATenGame.tsx - Feedback screen
src/components/TheyreATenGame.tsx - Bag reset
src/components/TheyreATenGame.tsx
Game content
- Question ratings
src/data/questions.json - Team roster
src/data/teamMembers.json - Game data types
src/types/game.ts
Feedback effects
- Sound effects
- Confetti effect
Other components
- Player
Connections 17
- Player → React bootstrap: opens game
README.md - React bootstrap → App wrapper: renders
src/main.tsx - App wrapper → Game controller: renders
src/App.tsx - Game controller → Start screen: renders
src/components/TheyreATenGame.tsx - Player → Start screen: starts round
src/components/TheyreATenGame.tsx - Game controller → Round sampling: requests round
src/components/TheyreATenGame.tsx - Round sampling → Question ratings: draws questions
src/components/TheyreATenGame.tsx - Round sampling → Team roster: looks up member
src/components/TheyreATenGame.tsx - Game controller → Question screen: renders
src/components/TheyreATenGame.tsx - Player → Question screen: submits guess
src/components/TheyreATenGame.tsx - Game controller → Feedback screen: renders
src/components/TheyreATenGame.tsx - Player → Feedback screen: chooses next or reset
src/components/TheyreATenGame.tsx - Game controller → Round sampling: resets bags
src/components/TheyreATenGame.tsx - Game controller → Sound effects: plays effects
src/components/TheyreATenGame.tsx - Feedback screen → Confetti effect: celebrates exact match
src/components/TheyreATenGame.tsx - Question ratings → Game data types: conforms to
README.md - Team roster → Game data types: conforms to
README.md