Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Packet

Hierarchy

Implements

Index

Properties

Protected bufferSize

bufferSize: number

Protected byteArray

byteArray: Uint8Array

Protected byteOffset

byteOffset: number

Protected connection

connection: IConnection

constructor

Protected dataView

dataView: DataView

Protected synchronizationCheckData

synchronizationCheckData: ISynchronizationCheckData

Static Protected id

id: number

Methods

getAllowedStates

getArrayBuffer

  • getArrayBuffer(id?: number): ArrayBuffer
  • Parameters

    • Optional id: number

    Returns ArrayBuffer

getId

  • getId(): number

Protected getInitialBufferSize

  • getInitialBufferSize(): number
  • Returns number

getSynchronizationCheckData

getType

  • getType(): PacketType.Client | PacketType.Server | PacketType.Shared
  • Returns PacketType.Client | PacketType.Server | PacketType.Shared

isSyncCheckEnabled

  • isSyncCheckEnabled(): boolean

Protected preProcess

  • preProcess(): void
  • Returns void

Protected preReadData

  • preReadData(): void
  • Returns void

Protected preWriteData

  • preWriteData(): void
  • Returns void

process

  • process(): any
  • Returns any

processAndSend

  • Parameters

    Returns any

processData

  • processData(dataView: DataView): void
  • Parameters

    • dataView: DataView

    Returns void

Protected readBool

  • readBool(): boolean
  • Returns boolean

Protected readContainer

Protected readCreature

Protected readData

  • readData(): void
  • Returns void

Protected readDoodad

Protected readFloat64

  • readFloat64(): number

Protected readIndexedBool

  • readIndexedBool(): boolean | undefined

Protected readIndexedContainer

Protected readIndexedCreature

  • readIndexedCreature(): ICreature | undefined

Protected readIndexedDoodad

  • readIndexedDoodad(): IDoodad | undefined

Protected readIndexedFloat64

  • readIndexedFloat64(): number | undefined

Protected readIndexedItem

  • readIndexedItem(): IItem | undefined

Protected readIndexedItemOrDoodad

Protected readIndexedItems

  • readIndexedItems(): IItem[] | undefined

Protected readIndexedObject

  • readIndexedObject(): any

Protected readIndexedPoint

  • readIndexedPoint(): IPoint | undefined

Protected readIndexedString

  • readIndexedString(): string | undefined

Protected readIndexedStringArray

  • readIndexedStringArray(): string[] | undefined

Protected readIndexedUint16

  • readIndexedUint16(): number | undefined

Protected readIndexedUint32

  • readIndexedUint32(): number | undefined

Protected readIndexedUint32NumberArray

  • readIndexedUint32NumberArray(): number[] | undefined

Protected readIndexedUint8

  • readIndexedUint8(): number | undefined

Protected readIndexedUint8Array

  • readIndexedUint8Array(): Uint8Array | undefined

Protected readItem

Protected readItemOrDoodad

Protected readItems

Protected readObject

  • readObject(): any

Protected readPoint

Protected readString

  • readString(): string
  • Returns string

Protected readStringArray

  • readStringArray(): string[]

Protected readUint16

  • readUint16(): number
  • Returns number

Protected readUint32

  • readUint32(): number
  • Returns number

Protected readUint32NumberArray

  • readUint32NumberArray(): number[]

Protected readUint8

  • readUint8(): number
  • Returns number

Protected readUint8Array

  • readUint8Array(): Uint8Array

Protected resetIndexes

  • resetIndexes(): void

send

  • Parameters

    Returns void

sendTo

  • Parameters

    Returns void

Protected writeBool

  • writeBool(value: boolean): void
  • Parameters

    • value: boolean

    Returns void

Protected writeContainer

Protected writeCreature

Protected writeData

  • writeData(): void
  • Returns void

Protected writeDoodad

  • writeDoodad(value: IDoodad): void

Protected writeFloat64

  • writeFloat64(value: number): void
  • Parameters

    • value: number

    Returns void

Protected writeIndexedBool

  • writeIndexedBool(value?: boolean): void
  • Parameters

    • Optional value: boolean

    Returns void

Protected writeIndexedContainer

Protected writeIndexedCreature

  • writeIndexedCreature(value?: ICreature): void

Protected writeIndexedDoodad

  • writeIndexedDoodad(value?: IDoodad): void

Protected writeIndexedFloat64

  • writeIndexedFloat64(value?: number): void

Protected writeIndexedItem

  • writeIndexedItem(value?: IItem): void

Protected writeIndexedItemOrDoodad

Protected writeIndexedItems

  • writeIndexedItems(value?: IItem[]): void

Protected writeIndexedObject

  • writeIndexedObject(value?: any): void

Protected writeIndexedPoint

  • writeIndexedPoint(value?: IPoint): void

Protected writeIndexedString

  • writeIndexedString(value?: string): void

Protected writeIndexedStringArray

  • writeIndexedStringArray(value?: string[]): void

Protected writeIndexedUint16

  • writeIndexedUint16(value?: number): void

Protected writeIndexedUint32

  • writeIndexedUint32(value?: number): void

Protected writeIndexedUint32NumberArray

  • writeIndexedUint32NumberArray(value?: number[]): void

Protected writeIndexedUint8

  • writeIndexedUint8(value?: number): void

Protected writeIndexedUint8Array

  • writeIndexedUint8Array(value?: Uint8Array): void

Protected writeItem

  • writeItem(value: IItem): void
  • Parameters

    Returns void

Protected writeItemOrDoodad

Protected writeItems

  • writeItems(value: IItem[]): void
  • Parameters

    Returns void

Protected writeObject

  • writeObject(value: any): void
  • Parameters

    • value: any

    Returns void

Protected writePoint

  • writePoint(value: IPoint): void

Protected writeString

  • writeString(value: string): void
  • Parameters

    • value: string

    Returns void

Protected writeStringArray

  • writeStringArray(value: string[]): void
  • Parameters

    • value: string[]

    Returns void

Protected writeUint16

  • writeUint16(value: number): void
  • Parameters

    • value: number

    Returns void

Protected writeUint32

  • writeUint32(value: number): void
  • Parameters

    • value: number

    Returns void

Protected writeUint32NumberArray

  • writeUint32NumberArray(value: number[]): void

Protected writeUint8

  • writeUint8(value: number): void
  • Parameters

    • value: number

    Returns void

Protected writeUint8Array

  • writeUint8Array(value: Uint8Array): void
  • Parameters

    • value: Uint8Array

    Returns void

Static getId

  • getId(): number
  • Returns number

Static setId

  • setId(id: number): void
  • Parameters

    • id: number

    Returns void

Generated using TypeDoc