Options
All
  • Public
  • Public/Protected
  • All
Menu

Class MultipeerAdapter

The MultipeerAdapter is appropriate to use when the host environment has no authoritative server simulation, where each client owns some part of the simulation, and a connection from each client to the Mixed Reality Extension (MRE) app is necessary. The MultipeerAdapter serves as an aggregation point for these client connections. This adapter is responsible for app state synchronization to new clients, and for managing distributed state ownership (i.e., which client is authoritative over what parts of the simulated state).

Example hosts:

  • AltspaceVR
  • Peer-to-peer multiuser topologies

Hierarchy

Index

Constructors

Events

Accessors

Methods

Constructors

constructor

Events

onConnection

  • onConnection(handler: function): this
  • The onConnection event is raised when a new Context is created for an application session. This happens when the first client connects to your application.

    Parameters

    Returns this

Accessors

port

  • get port(): string | number
  • Returns string | number

server

  • get server(): Server
  • set server(value: Server): void
  • Returns Server

  • Parameters

    • value: Server

    Returns void

Methods

listen

  • listen(): Promise<Server>
  • Start the adapter listening for new incoming connections from engine clients

    Returns Promise<Server>