Class: SystemInput

SystemInput


new SystemInput()

Source:

Methods


bind(key, action)

Bind a key to a specific action.

Parameters:
Name Type Description
key String

Key to bind

action String

Action name

Source:
Returns:

Self for chaining

Type
SystemInput

pressed(action)

Whether an action is just pressed.

Parameters:
Name Type Description
action String

Action name

Source:
Returns:

Pressed or not

Type
Boolean

released(action)

Whether an action is just released.

Parameters:
Name Type Description
action String

Action name

Source:
Returns:

Released or not

Type
Boolean

state(action)

Whether an action is currently pressed.

Parameters:
Name Type Description
action String

Action name

Source:
Returns:

Pressed or not

Type
Boolean

unbind(key, action)

Unbind an action from a key.

Parameters:
Name Type Description
key String

Key to unbind

action String

Action to unbind

Source:
Returns:

Self for chaining

Type
SystemInput

unbindAll()

Unbind all the actions.

Source:

Class: SystemInput

SystemInput


new SystemInput()

Input system which provides key bindings.

Source:

Methods


bind(key, action)

Bind a key to a specific action.

Parameters:
Name Type Description
key String

Key to bind

action String

Action name

Source:
Returns:

Self for chaining

Type
SystemInput

pressed(action)

Whether an action is just pressed.

Parameters:
Name Type Description
action String

Action name

Source:
Returns:

Pressed or not

Type
Boolean

released(action)

Whether an action is just released.

Parameters:
Name Type Description
action String

Action name

Source:
Returns:

Released or not

Type
Boolean

state(action)

Whether an action is currently pressed.

Parameters:
Name Type Description
action String

Action name

Source:
Returns:

Pressed or not

Type
Boolean

unbind(key, action)

Unbind an action from a key.

Parameters:
Name Type Description
key String

Key to unbind

action String

Action to unbind

Source:
Returns:

Self for chaining

Type
SystemInput

unbindAll()

Unbind all the actions.

Source: