Skip to content

[Feature] Multiplayer: sessions, replication and transports #1243

Description

@miogds

Goal

Two or more players in the same game: side by side in one room on their headsets, or apart on a FaceTime call with spatial Personas, or over the network from a Mac or an iPhone, seeing the same scene, the same zombies and each other's actions at the same moment. The engine has no networking today. CoolSaber proves the first form on its own: a SharePlay duel between two Vision Pros through GroupActivities, with a shared group-immersive-space origin and the blade state synced by code that lives inside the demo, so every other game would have to write the same thing again.

The goal is a multiplayer layer in the engine that a game turns on rather than builds: a session (who is in, joining and leaving, the shared origin in a room), replication of entity state marked as networked (transforms, animation goals, physics ownership, plugin values) with snapshots, deltas and interpolation so remote entities move smoothly, an authority model (one host or a server owning the simulation, clients predicting their own player), events between peers for gameplay, and a transport chosen per situation: SharePlay for visionOS sessions with Personas and voice for free, the local network for a room without FaceTime, a dedicated server later for remote play at scale. The editor marks what is replicated; the same scene runs single-player unchanged.

Status

Step Plan Status
Proof in a demo SharePlay duel with spatial Personas, shared origin, blade state sync Done in CoolSaber (its own code)
Requirements Co-located and remote forms, player count, what the game replicates (players, zombies, physics props), authority model, latency budget on visionOS Not started
Session Join and leave, participant identity, shared spatial origin, reconnection Not started
Transport GroupActivities first (visionOS, iOS, macOS), local network second, dedicated server later, behind one interface Not started
Replication Networked component marking, snapshots and deltas, interpolation and extrapolation, ownership transfer Not started
Authority and prediction Host or server simulation, client-side prediction for the local player, reconciliation Not started
Physics and animation Jolt state ownership per body, motion-matching goals replicated instead of poses Not started
Editor Mark entities as replicated, session debug panel Not started
Sample CoolSaber's sync moved onto the engine layer; a two-player zombie room Not started

Next steps

  • Requirements note, then session and replication over GroupActivities, with CoolSaber as the first migration.
  • Depends on the physics seam for body ownership and on the motion-matching extensions for goal replication.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions