Collaboration
The map editor supports real-time collaborative editing, allowing multiple users to work on the same map simultaneously.
How It Works
Section titled “How It Works”Collaboration is powered by Yjs, a CRDT (Conflict-free Replicated Data Type) library. When multiple users open the same map:
- Each user connects to a shared Yjs document via WebSocket
- Changes are broadcast to all connected users in real-time
- Yjs automatically resolves conflicts — no manual merging needed
- The scene state is eventually consistent across all clients
Using Collaboration
Section titled “Using Collaboration”Start a Session
Section titled “Start a Session”- Open a map in the editor at editor.ctx.gg
- Share the map URL with collaborators
- Anyone with the URL can join and edit
What’s Synchronized
Section titled “What’s Synchronized”- Entity creation and deletion
- Transform changes (position, rotation, scale)
- Material and property updates
- Scene tree structure
Awareness
Section titled “Awareness”Each connected user has a cursor and selection indicator visible to others. You can see:
- Who is currently editing
- What object each user has selected
- Real-time transform updates as others drag objects
Offline Support
Section titled “Offline Support”If you lose connection, your changes are preserved locally. When reconnected, Yjs automatically syncs your changes with the server and other clients.
Limitations
Section titled “Limitations”- Large maps with many simultaneous editors may experience slight latency
- Binary assets (textures, models) are not synced via Yjs — they are uploaded to the API separately