@pureweb/platform-streaming-agent
Version:
The PureWeb platform streaming agent enables your game to communicate and stream through the PureWeb Platform
52 lines (51 loc) • 1.51 kB
TypeScript
import { AbstractExtension } from '../../IExtension';
import { IConnectionService } from '../../IConnectionService';
import { ConnectionStates } from '../../ConnectionStates';
import { Contribution } from '@pureweb/platform-sdk';
declare enum HMDState {
NOT_PRESENT = 0,
INACTIVE = 1,
ACTIVE = 2
}
declare enum PresenceState {
NOT_PRESENT = 0,
PRESENT = 1
}
declare enum GameConnectionState {
CONNECTED = 0,
DISCONNECTED = 1
}
declare enum EventStreamState {
OPEN = 0,
CLOSED = 1,
ERROR = 2
}
export declare class SteamVRLogMonitorExtension extends AbstractExtension implements IConnectionService {
private connectionStateChange;
private ws;
private currentReconnectDelay;
id: number;
IP: Promise<string>;
contribution: Contribution;
steamVRState: HMDState;
presenceState: PresenceState;
gameState: GameConnectionState;
eventStreamState: EventStreamState;
activePID: string;
constructor();
fetchPublicIP: () => Promise<string>;
makeIPContribution: () => Promise<void>;
revokeIPContribution: () => Promise<void>;
private monitor;
onWebsocketOpen(): void;
start: () => Promise<boolean>;
stop: () => Promise<boolean>;
onStateChanged(handler: (state: ConnectionStates) => void): void;
startRendezvousTimer(): void;
onRuntimeEventStreamConnection(): void;
private monitorPresence;
private onAgentArrival;
private onAgentDeparture;
startPresenceTimer(): void;
}
export {};