A modern, web-based Virtual Tabletop (VTT) environment. This monorepo includes a React frontend utilizing @primer/react and an Express/Socket.io backend for real-time multiplayer coordination.
- Real-time Multiplayer: Seamless cursor tracking, active player rosters, and a live chat log.
- Game Master Workstation: GMs can configure campaigns, manage active battlemaps, and orchestrate standard setups.
- Persistent Library System: A hierarchy-friendly token and card library saved onto the host environment, equipped with drag-and-drop spawn capabilities and
.ziploss-less exporting. - Dynamic Canvas: Grid overlays responsive to light/dark system themes, featuring an unobtrusive cursor coordinate heads-up display.
- Modern Aesthetics: Designed with CSS glassmorphism, fluid micro-animations, and the robust Primer design token system.
The repository uses npm workspaces to manage its packages.
packages/shared: Shared TypeScript interfaces and socket event topologies.packages/frontend: The React/Vite front-end.packages/backend: The Node.js Express/Socket.io backend server. Maps and campaign data are persisted in a generatedcampaigns/folder relative to the backend.
Ensure you have Node.js installed along with npm v7+.
-
Install all dependencies across the monorepo from the root directory:
npm install
-
Start the development servers (runs both frontend on port
5173and backend on port3005):npm run dev
-
Navigate to
http://localhost:5173in your browser.
- Enter a generic Campaign string and enter your desired screen name.
- The very first user to input "GM" in the passkey block (or claim GM button) will become the host with exclusive access to map controls and the Library tab.
- Observers and players joining later will only be able to control objects on the canvas assigned to them or marked as public.
- Drag and drop default Slug and Snail entities from the GM's Library tab directly onto the Stage!
This implementation was generated autonomously. V2 features include modular sidebars, an exportable hierarchical asset library, persistent dark mode user settings, and coordinate/grid systems. For further modifications, edit packages/frontend/src/App.tsx or expand the entity contracts in packages/shared/src/index.ts.