Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Vector2

A Unity Vector2 helper class with serialization and deserialization methods.

Hierarchy

  • Vector2

Index

Constructors

Properties

Methods

Constructors

constructor

  • new Vector2(x: number, y: number): Vector2
  • Parameters

    • x: number
    • y: number

    Returns Vector2

Properties

x

x: number

y

y: number

Methods

write

  • write(bb: ByteBuffer): void
  • Write the Vector2 to a buffer and correctly linearly interpolate the values.

    Parameters

    • bb: ByteBuffer

      Buffer to write to

    Returns void

Static read

  • Read a Vector2 from a buffer and correctly linearly interpolate the values.

    Parameters

    • bb: ByteBuffer

      Buffer to read from

    Returns Vector2

Generated using TypeDoc