How kbl13350/kartsim works
KartSim is a browser kart-racing game with a TypeScript client and Go backend; the README also identifies original game resources and a separate admin console. The principal player flow is choosing a mode and kart, loading resources, racing with driving physics and (for multiplayer) networked participants, then viewing results and rewards. The graph preserves the documented account, economy, social, and mode-specific features. Most cross-module wiring is documented at product level; edges based on unsampled subsystems cite the README rather than implying source-level calls.
Main entry points: main.ts Game client · ready-controller.ts Mode and garage setup · frame-pipeline.ts Driving physics · server.go Data service
Components 25
Browser game
- Game client
client/src/main.ts - Mode and garage setup
client/src/timeattack/ready-controller.ts - Resource loading
client/src/resources/resource-manager.ts - Driving physics
client/src/driving/frame-pipeline.ts - Item race rules
client/src/item/item-race-controller.ts - Race presentation
client/src/ui/race-hud-controller.ts - Time attack and ghosts
client/src/timeattack/ghost-runtime.ts - Race results and rewards
client/src/game/race-results.ts - Accounts and profile
client/src/account/account-runtime.ts - Garage and inventory
client/src/ui/garage-view-construction.ts - Shop and economy UI
client/src/shop/shop-view.ts - Social features
client/src/club/club-screen.ts - Multiplayer lobby
client/src/multiplayer/lobby-controller.ts - Networked race
client/src/multiplayer/race-session.ts - Missions and game modes
client/src/license/license-mission.ts - Client service APIs
client/src/game/api.ts
Go backend
- Data service
server-go/internal/data/server/server.go - Accounts and economy
server-go/internal/data/economy/economy.go - Persistent data
server-go/internal/data/store/storage.go - Game node
server-go/internal/game/app/app.go - Rooms and races
server-go/internal/game/lobby/lobby.go
Admin console
- Admin console
server-go/admin-ui/src/App.vue - Admin API client
server-go/admin-ui/src/api/client.ts
Game resources
- Original game resources
mirror
Other components
- Player
Connections 27
- Player → Game client: plays
README.md - Game client → Mode and garage setup: selects mode
README.md - Mode and garage setup → Resource loading: loads assets
- Resource loading → Original game resources: reads resources
README.md - Mode and garage setup → Driving physics: starts race
- Driving physics → Item race rules: advances item effects
- Driving physics → Race presentation: updates presentation
- Item race rules → Race presentation: feeds item HUD
- Mode and garage setup → Multiplayer lobby: opens multiplayer
client/src/timeattack/ready-controller.ts - Multiplayer lobby → Networked race: loads race
- Networked race → Game node: exchanges race data
README.md - Game node → Rooms and races: runs rooms
README.md - Game client → Client service APIs: requests services
- Client service APIs → Data service: calls backend
README.md - Data service → Accounts and economy: serves economy
README.md - Data service → Persistent data: persists data
README.md - Game client → Time attack and ghosts: runs time attack
README.md - Time attack and ghosts → Race results and rewards: records results
- Driving physics → Race results and rewards: finishes race
- Game client → Accounts and profile: supports login
README.md - Game client → Garage and inventory: opens garage
README.md - Game client → Shop and economy UI: opens shop
README.md - Game client → Social features: supports social play
README.md - Game client → Missions and game modes: offers missions
README.md - Player → Admin console: administers
README.md - Admin console → Admin API client: requests admin data
server-go/admin-ui/src/App.vue - Admin API client → Data service: calls admin API