Class UserInput

Handles user input

Hierarchy

  • UserInput

Constructors

Properties

Methods

Constructors

  • Creates a new UserInput object

    See

    Main

    Parameters

    • main: Main

      Main object

    Returns UserInput

Properties

keyUsed: boolean = false
lastKey: string = null
main: Main

Methods

  • Updates the game based on the last key pressed

    Parameters

    • isGravityTick: boolean

      Whether or not this is a tick where gravity is applied

    Returns void

Generated using TypeDoc