Class Button

Key is used by Keyboard and Mouse, to represent a key state.

Hierarchy (view full)

Constructors

Properties

justPressed: boolean = false

Indicates if this key was just pressed.

justReleased: boolean = false

Indicates if this key was just released.

pressed: boolean = false

Indicates if this key is currently pressed.

Methods

  • Reset key to default values.

    Returns void

  • Set this key attributes manually.

    Parameters

    • justPressed: boolean

      Indicate if the button was just pressed.

    • pressed: boolean

      Indicate if the button is pressed.

    • justReleased: boolean

      Indicate if the button was just released.

    Returns void

  • Update Key status based on new key state.

    Parameters

    Returns void