import { EnterRoom } from "./signal/signal-room"; import { SigType, SigPayload } from "./webrtc-peer-collector"; type UserListener = (user: string, action: "join" | "leave", users: string[]) => void; export declare function enterWorld({ userId: passedUserId, worldId, logLine, enterRoomFunction, peerlessUserExpiration, workerUrl, onRoomReady, onRoomClose, dataChannelOptions, }: { userId?: string; worldId: string; logLine?: (...obj: any[]) => void; enterRoomFunction?: EnterRoom; peerlessUserExpiration?: number; workerUrl?: URL; onRoomReady?(info: { host: string; room: string; }): void; onRoomClose?(info: { host: string; room: string; ev: Pick; }): void; dataChannelOptions?: RTCDataChannelInit; }): { userId: string; send: (data: S, userId?: string) => void; broadcast:

(payload: P) => void; enterRoom: ({ room, host, protocol, }: { room: string; host: string; protocol?: string; }) => Promise; exitRoom: ({ room, host }: { room: string; host: string; }) => void; leaveUser: (userId: string) => void; getUsers: () => string[]; addMessageListener: (listener: (data: R, from: string) => void) => () => void; removeMessageListener: (listener: (data: R, from: string) => void) => void; addUserListener: (listener: UserListener) => () => void; removeUserListener: (listener: UserListener) => void; reset(): void; end(): void; }; export {}; //# sourceMappingURL=enter-world.d.ts.map