Transport: {
    allowReservedEntities?: boolean;
    type?: string;
    filter(message: Omit<TransportMessage, "messageBuffer">): boolean;
    onmessage?(message: Uint8Array): void;
    send(message: Uint8Array | Uint8Array[]): Promise<void>;
}

Type declaration

  • Optional allowReservedEntities?: boolean

    Whether this transport is allowed to mutate reserved-range entities (root/player/camera + avatars, entity number below RESERVED_STATIC_ENTITIES). Only the trusted host/renderer transport sets this. An inbound DELETE_ENTITY or component operation (PUT_COMPONENT, DELETE_COMPONENT, APPEND_VALUE, AUTHORITATIVE_PUT_COMPONENT) on a reserved entity from a transport without this flag (a comms peer, or any scene-added transport) is rejected — see receiveMessages.

  • Optional type?: string
  • filter:function
    • Parameters

      Returns boolean

  • onmessage?:function
    • Parameters

      • message: Uint8Array

      Returns void

  • send:function
    • For Network messages its an Uint8Array[]. Due too the LiveKit MAX_SIZE = 13kb For Renderer & Other transports we send a single Uint8Array

      Parameters

      • message: Uint8Array | Uint8Array[]

      Returns Promise<void>