Options
All
  • Public
  • Public/Protected
  • All
Menu

Class InitialGameDumpPacket

typedef

{{ resources: Array<import("../client_simulation_result").SimResultResource>, dump: import("../client_simulation_result").ClientSimulationResult }} InitialGameDump

Hierarchy

Index

Constructors

constructor

  • Parameters

    • Default value data: object = { dump: null, rngSeed: 0, minUid: 0, maxUid: 999999, safeUidStart: 99999999, mapTheme: null }
      • dump: null
      • mapTheme: null
      • maxUid: number
      • minUid: number
      • rngSeed: number
      • safeUidStart: number

    Returns InitialGameDumpPacket

Methods

getConstructor

  • getConstructor(): Function
  • Returns Function

getDump

  • getDump(): any
  • Returns any

getMapTheme

  • getMapTheme(): any
  • Returns any

getMaxUid

  • getMaxUid(): any
  • Returns any

getMinUid

  • getMinUid(): any
  • Returns any

getNiceData

  • getNiceData(): object
  • Returns object

    • mapTheme: any
    • maxUid: any
    • minUid: any
    • resources: any
    • rngSeed: any
    • safeUidStart: any

getNiceString

  • getNiceString(): string
  • Returns a nice string of this packet

    Returns string

getRngSeed

  • getRngSeed(): any
  • Returns any

getSafeUidStart

  • getSafeUidStart(): any
  • Returns any

getTransformedDataBeforeSend

  • getTransformedDataBeforeSend(): any

serialize

  • serialize(): Uint8Array
  • Serializes this packet into an array buffer

    Returns Uint8Array

Static getHeaderPacketId

  • getHeaderPacketId(): any
  • Returns the number id used for serializing / deserializing

    Returns any

Static getId

  • getId(): string
  • Returns string

Static getMaxSerializedLength

  • getMaxSerializedLength(): number

Static getSchemaUnprocessed

  • getSchemaUnprocessed(): object
  • Returns object

    • additionalProperties: boolean
    • properties: any
    • required: string[]
    • type: string

Static getSerializers

  • getSerializers(): any
  • Returns the schema used for serialization / deserialization

    Returns any

Static hasPayload

  • hasPayload(): boolean
  • Returns if the packet has some payload

    Returns boolean

Static precompileSchema

  • precompileSchema(): object
  • Precompiles the schema

    Returns object

    • validate: any

Static transformDataAfterReceive

  • transformDataAfterReceive(data: any): any
  • Override to transform data after receiving

    Parameters

    • data: any

    Returns any

Static tryParse

  • Tries to parse the given buffer

    Parameters

    • binaryData: any

    Returns BasePacket