How ctrl-alt-transcend/smrow-game works
Goblin vs Wizards is a browser-based multiplayer Catan-like game with accounts, lobbies, social features, and player statistics. The main workflow is authentication, joining or creating a lobby, then playing through the game UI with backend game state and live updates; results feed statistics. The README specifically highlights creating and joining a lobby. The graph combines sampled call evidence with documented capabilities and tree-supported subsystems; unsampled frontend socket and game-state wiring is left unasserted.
Main entry points: game.service.ts Game orchestration · user.service.ts User and friendship service · database.service.ts PostgreSQL database · auth.service.ts Authentication service
Components 22
Web client
- Application routes
app/frontend/src/routes/routes.tsx - Authentication UI
app/frontend/src/context/AuthProvider.tsx - Home and lobby UI
app/frontend/src/components/home/GameLaunchMenu.tsx - Game interface
app/frontend/src/game/GameShell.tsx - Stats pages
app/frontend/src/pages/StatsPage.tsx - HTTP API client
app/frontend/src/services/http.tsx
Identity and profiles
- Authentication API
app/backend/src/auth/auth.controller.ts - Authentication service
app/backend/src/auth/auth.service.ts - User and friendship service
app/backend/src/user/user.service.ts
Game and lobbies
- Game endpoints
app/backend/src/game/game.controller.ts - Game orchestration
app/backend/src/game/game.service.ts - Game rules and state
app/backend/src/game/GameStateContext.ts - Live game gateway
app/backend/src/game/game.gateway.ts - Lobby listing
app/backend/src/games/games.controller.ts - Lobby service
app/backend/src/games/games.service.ts
Social
- Friends UI
app/frontend/src/components/social/FriendList.tsx - Social endpoints
app/backend/src/user/user.controller.ts - Social gateway
app/backend/src/social/social.gateway.ts
Statistics and persistence
- Stats endpoints
app/backend/src/stats/stats.controller.ts - Stats service
app/backend/src/stats/stats.service.ts - PostgreSQL database
app/backend/src/database/database.service.ts
Other components
- Player
Connections 28
- Player → Application routes: uses
app/frontend/src/routes/routes.tsx - Application routes → Authentication UI: renders
app/frontend/src/context/AuthProvider.tsx - Player → Home and lobby UI: creates or joins
- Player → Game interface: plays
- Player → Stats pages: views
- Authentication UI → HTTP API client: requests
app/frontend/src/context/AuthProvider.tsx - HTTP API client → Authentication API: HTTP calls
- Player → Authentication API: authenticates
- Authentication API → Authentication service: delegates
app/backend/src/auth/auth.controller.ts - Authentication service → User and friendship service: manages users
app/backend/src/auth/auth.service.ts - Authentication service → PostgreSQL database: reads and writes
app/backend/src/auth/auth.service.ts - Player → Game endpoints: creates or joins
app/backend/src/game/game.controller.ts - Game endpoints → Game orchestration: delegates
app/backend/src/game/game.controller.ts - Game endpoints → User and friendship service: loads profile
app/backend/src/game/game.controller.ts - Game orchestration → Game rules and state: manages state
app/backend/src/game/game.service.ts - Game orchestration → Live game gateway: uses gateway
app/backend/src/game/game.service.ts - Game orchestration → Social gateway: uses gateway
app/backend/src/game/game.service.ts - Game orchestration → Stats service: records results
app/backend/src/game/game.service.ts - Player → Lobby listing: views lobbies
- Lobby listing → Lobby service: delegates
app/backend/src/games/games.controller.ts - Lobby service → PostgreSQL database: reads
app/backend/src/games/games.service.ts - Player → Friends UI: manages friends
- Friends UI → Social endpoints: HTTP requests
- Social endpoints → User and friendship service: delegates
app/backend/src/user/user.controller.ts - User and friendship service → PostgreSQL database: reads and writes
app/backend/src/user/user.service.ts - Player → Stats endpoints: requests stats
app/backend/src/stats/stats.controller.ts - Stats endpoints → Stats service: delegates
app/backend/src/stats/stats.controller.ts - Stats service → PostgreSQL database: reads and writes
app/backend/src/stats/stats.service.ts