Options
All
  • Public
  • Public/Protected
  • All
Menu

Class that deals with time. In this base class, you need to set time manually from Automaton.update(). Best for sync with external clock stuff.

Hierarchy

Index

Constructors

Properties

__deltaTime: number = 0.0

Its deltaTime of last update.

__isPlaying: boolean = false

Whether its currently playing or not.

__time: number = 0.0

Its current time.

Accessors

  • get deltaTime(): number
  • get isPlaying(): boolean
  • get time(): number

Methods

  • pause(): void
  • play(): void
  • setTime(time: number): void
  • Set the time manually.

    Parameters

    • time: number

      Time

    Returns void

  • update(time?: number): void
  • Update the clock.

    Parameters

    • Optional time: number

      Time. You need to set manually when you are using manual Clock

    Returns void

Generated using TypeDoc