UNPKG

multyx-client

Version:

Framework designed to simplify the creation of multiplayer browser games by addressing the complexities of managing server-client communication, shared state, and input handling

123 lines (122 loc) 2.93 kB
import { Update } from "./types"; export declare function UncompressUpdate(str: string): { instruction: string; team: boolean; path: string[]; value: any; property?: undefined; data?: undefined; name?: undefined; response?: undefined; uuid?: undefined; publicData?: undefined; clientUUID?: undefined; client?: undefined; tps?: undefined; constraintTable?: undefined; clients?: undefined; teams?: undefined; space?: undefined; } | { instruction: string; property: string; data: any; team?: undefined; path?: undefined; value?: undefined; name?: undefined; response?: undefined; uuid?: undefined; publicData?: undefined; clientUUID?: undefined; client?: undefined; tps?: undefined; constraintTable?: undefined; clients?: undefined; teams?: undefined; space?: undefined; } | { instruction: string; name: string; response: any; team?: undefined; path?: undefined; value?: undefined; property?: undefined; data?: undefined; uuid?: undefined; publicData?: undefined; clientUUID?: undefined; client?: undefined; tps?: undefined; constraintTable?: undefined; clients?: undefined; teams?: undefined; space?: undefined; } | { instruction: string; uuid: string; publicData: any; team?: undefined; path?: undefined; value?: undefined; property?: undefined; data?: undefined; name?: undefined; response?: undefined; clientUUID?: undefined; client?: undefined; tps?: undefined; constraintTable?: undefined; clients?: undefined; teams?: undefined; space?: undefined; } | { instruction: string; clientUUID: string; team?: undefined; path?: undefined; value?: undefined; property?: undefined; data?: undefined; name?: undefined; response?: undefined; uuid?: undefined; publicData?: undefined; client?: undefined; tps?: undefined; constraintTable?: undefined; clients?: undefined; teams?: undefined; space?: undefined; } | { instruction: string; client: any; tps: any; constraintTable: any; clients: any; teams: any; space: any; team?: undefined; path?: undefined; value?: undefined; property?: undefined; data?: undefined; name?: undefined; response?: undefined; uuid?: undefined; publicData?: undefined; clientUUID?: undefined; }; export declare function CompressUpdate(update: Update): string; export declare class Message { name: string; data: any; time: number; native: boolean; private constructor(); static BundleOperations(deltaTime: number, operations: Update[]): string; static Native(update: Update): string; static Parse(str: string): Message; static Create(name: string, data: any): string; }