# mahip-jain/fa26-mp-codebases-geouiuc architecture

> Architecture diagram of the GitHub repository mahip-jain/fa26-mp-codebases-geouiuc, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-18). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/mahip-jain/fa26-mp-codebases-geouiuc
- Repository: https://github.com/mahip-jain/fa26-mp-codebases-geouiuc

## Overview

GeoUIUC is a campus-location guessing game: a player signs in, enters the lobby, plays rounds using a Street View location and map guess, then sees a score and can return to the lobby. Firebase supports Google authentication and player records; profile and settings provide adjacent account and audio controls. The graph includes the older game implementation because it is a core indexed module. Some subsystem links are grounded only in README or index references; unsampled implementation details are not inferred.

Main entry points: [`Frontend/src/app/game/page.js`](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/game/page.js) (Game round), [`Frontend/src/app/login/page.js`](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/login/page.js) (Login page), [`Frontend/src/app/lobby/page.js`](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/lobby/page.js) (Game lobby), [`Frontend/src/app/layout.js`](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/layout.js) (Application shell)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_play["Game play"]
  node_lobby["Game lobby<br/>[page.js]"]
  node_game["Game round<br/>[page.js]"]
  node_guessmap["Guess map<br/>[GuessMap.js]"]
  node_randompoint["Campus point picker<br/>[randpoint.js]"]
  node_scorescreen["Round scoring<br/>[ScoreScreen.js]"]
  node_backupgame["Legacy game round<br/>[page-backup.js]"]
  node_resultpage["Results page<br/>[page.js]"]
  node_scorebar["Result score bar<br/>[ScoreBar.js]"]
end

subgraph group_account["Accounts and profiles"]
  node_login["Login page<br/>[page.js]"]
  node_profile["Player profile<br/>[page.js]"]
  node_loginbutton["Google login button<br/>[LoginButton.js]"]
  node_deletepopup["Delete confirmation"]
end

subgraph group_shared["Shared interface"]
  node_layout["Application shell<br/>[layout.js]"]
  node_settings["Settings modal<br/>[SettingsModal.js]"]
  node_audio["Audio controls<br/>[AudioProvider.js]"]
  node_buttonaudio["Button sound effects<br/>[GlobalButtonSfx.js]"]
end

subgraph group_services["External services"]
  node_firebaseconfig["Firebase client<br/>[firebase-config.js]"]
  node_firebaseauth[("Firebase Auth")]
  node_firestore[("Player records")]
  node_googlemaps["Google Maps"]
end

node_player(("Player"))

node_player -->|"opens"| node_login
node_login -->|"renders"| node_loginbutton
node_loginbutton -->|"signs in through"| node_firebaseconfig
node_firebaseconfig -->|"initializes"| node_firebaseauth
node_login -->|"creates user record"| node_firestore
node_login -->|"routes signed-in player"| node_lobby
node_player -->|"enters"| node_lobby
node_lobby -->|"reads player record"| node_firestore
node_lobby -->|"starts round"| node_game
node_game -->|"chooses location"| node_randompoint
node_game -->|"renders map input"| node_guessmap
node_game -->|"shows round score"| node_scorescreen
node_game -->|"loads Street View and map"| node_googlemaps
node_player -.->|"can play legacy round"| node_backupgame
node_backupgame -->|"chooses location"| node_randompoint
node_player -->|"views account"| node_profile
node_profile -->|"reads player stats"| node_firestore
node_layout -->|"renders globally"| node_settings
node_layout -->|"provides audio context"| node_audio
node_layout -->|"renders globally"| node_buttonaudio
node_settings -->|"adjusts volumes"| node_audio
node_settings -->|"checks sign-in state"| node_firebaseauth
node_player -.->|"views results"| node_resultpage
node_resultpage -->|"renders"| node_scorebar
node_player -.->|"confirms account deletion"| node_deletepopup

click node_login "https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/login/page.js"
click node_lobby "https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/lobby/page.js"
click node_game "https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/game/page.js"
click node_guessmap "https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/game/GuessMap.js"
click node_randompoint "https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/game/test-scripts/randpoint.js"
click node_scorescreen "https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/game/ScoreScreen.js"
click node_backupgame "https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/game/page-backup.js"
click node_resultpage "https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/game/result/page.js"
click node_scorebar "https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/game/result/ScoreBar.js"
click node_profile "https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/profile/page.js"
click node_firebaseconfig "https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/components/firebase-config.js"
click node_layout "https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/layout.js"
click node_settings "https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/components/SettingsModal.js"
click node_audio "https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/components/AudioProvider.js"
click node_buttonaudio "https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/components/GlobalButtonSfx.js"
click node_loginbutton "https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/components/LoginButton.js"
click node_deletepopup "https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/components/ConfirmDeletePopUp.js"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_lobby,node_game,node_guessmap,node_randompoint,node_scorescreen,node_backupgame,node_resultpage,node_scorebar toneBlue
class node_login,node_profile,node_loginbutton,node_deletepopup toneAmber
class node_layout,node_settings,node_audio,node_buttonaudio toneMint
class node_firebaseconfig,node_firebaseauth,node_firestore,node_googlemaps toneRose
class node_player toneIndigo
```

## Components

### Game play

- [Game lobby](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/lobby/page.js): `Frontend/src/app/lobby/page.js`
- [Game round](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/game/page.js): `Frontend/src/app/game/page.js`
- [Guess map](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/game/GuessMap.js): `Frontend/src/app/game/GuessMap.js`
- [Campus point picker](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/game/test-scripts/randpoint.js): `Frontend/src/app/game/test-scripts/randpoint.js`
- [Round scoring](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/game/ScoreScreen.js): `Frontend/src/app/game/ScoreScreen.js`
- [Legacy game round](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/game/page-backup.js): `Frontend/src/app/game/page-backup.js`
- [Results page](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/game/result/page.js): `Frontend/src/app/game/result/page.js`
- [Result score bar](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/game/result/ScoreBar.js): `Frontend/src/app/game/result/ScoreBar.js`

### Accounts and profiles

- [Login page](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/login/page.js): `Frontend/src/app/login/page.js`
- [Player profile](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/profile/page.js): `Frontend/src/app/profile/page.js`
- [Google login button](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/components/LoginButton.js): `Frontend/src/components/LoginButton.js`
- [Delete confirmation](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/components/ConfirmDeletePopUp.js): `Frontend/src/components/ConfirmDeletePopUp.js`

### Shared interface

- [Application shell](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/app/layout.js): `Frontend/src/app/layout.js`
- [Settings modal](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/components/SettingsModal.js): `Frontend/src/components/SettingsModal.js`
- [Audio controls](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/components/AudioProvider.js): `Frontend/src/components/AudioProvider.js`
- [Button sound effects](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/components/GlobalButtonSfx.js): `Frontend/src/components/GlobalButtonSfx.js`

### External services

- [Firebase client](https://github.com/mahip-jain/fa26-mp-codebases-geouiuc/blob/main/Frontend/src/components/firebase-config.js): `Frontend/src/components/firebase-config.js`
- **Firebase Auth**
- **Player records**
- **Google Maps**

### Other components

- **Player**

## Connections

- Player → Login page: opens (evidence: `README.md`)
- Login page → Google login button: renders (evidence: `Frontend/src/app/login/page.js`)
- Google login button → Firebase client: signs in through (evidence: `Frontend/src/components/LoginButton.js`)
- Firebase client → Firebase Auth: initializes (evidence: `Frontend/src/components/firebase-config.js`)
- Login page → Player records: creates user record (evidence: `Frontend/src/app/login/page.js`)
- Login page → Game lobby: routes signed-in player (evidence: `Frontend/src/app/login/page.js`)
- Player → Game lobby: enters (evidence: `README.md`)
- Game lobby → Player records: reads player record (evidence: `Frontend/src/app/lobby/page.js`)
- Game lobby → Game round: starts round (evidence: `Frontend/src/app/lobby/page.js`)
- Game round → Campus point picker: chooses location (evidence: `Frontend/src/app/game/page.js`)
- Game round → Guess map: renders map input (evidence: `Frontend/src/app/game/page.js`)
- Game round → Round scoring: shows round score (evidence: `Frontend/src/app/game/page.js`)
- Game round → Google Maps: loads Street View and map (evidence: `README.md`)
- Player → Legacy game round: can play legacy round
- Legacy game round → Campus point picker: chooses location (evidence: `Frontend/src/app/game/page-backup.js`)
- Player → Player profile: views account (evidence: `README.md`)
- Player profile → Player records: reads player stats (evidence: `Frontend/src/app/profile/page.js`)
- Application shell → Settings modal: renders globally (evidence: `Frontend/src/app/layout.js`)
- Application shell → Audio controls: provides audio context (evidence: `Frontend/src/app/layout.js`)
- Application shell → Button sound effects: renders globally (evidence: `Frontend/src/app/layout.js`)
- Settings modal → Audio controls: adjusts volumes (evidence: `Frontend/src/components/SettingsModal.js`)
- Settings modal → Firebase Auth: checks sign-in state (evidence: `Frontend/src/components/SettingsModal.js`)
- Player → Results page: views results
- Results page → Result score bar: renders (evidence: `Frontend/src/app/game/result/page.js`)
- Player → Delete confirmation: confirms account deletion
