Options
All
  • Public
  • Public/Protected
  • All
Menu

Class to work with values, synchronized between server and all clients

Hierarchy

  • SyncedNetworkData

Index

Constructors

Methods

  • addOnDataChangedListener(func: ((networkData: SyncedNetworkData, isExternalChange: boolean) => void)): void
  • addVerifier(key: any, func: ((key: any, newValue: any) => void)): void
  • Adds data validator to the object

    Parameters

    • key: any
    • func: ((key: any, newValue: any) => void)
        • (key: any, newValue: any): void
        • Parameters

          • key: any
          • newValue: any

          Returns void

    Returns void

  • getBoolean(key: any, fallback?: boolean): boolean
  • getDouble(key: any, fallback?: number): number
  • getFloat(key: any, fallback?: number): number
  • getInt(key: any, fallback?: number): number
  • getLong(key: any, fallback?: number): number
  • getString(key: any, fallback?: string): string
  • putBoolean(key: any, value: boolean): void
  • putDouble(key: any, value: number): void
  • putFloat(key: any, value: number): void
  • putInt(key: any, value: number): void
  • putLong(key: any, value: number): void
  • putString(key: any, value: string): void
  • sendChanges(): void

Generated using TypeDoc