InputMapBuilder class
Fluent builder for InputMap.
Constructors
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
bindArrows(
ActionId action) → InputMapBuilder - Bind arrow keys to a Vector2 action.
-
bindDpad(
ActionId action, {String? gamepadId}) → InputMapBuilder - Bind D-pad to a Vector2 action.
-
bindGamepadAxis(
String axisKey, ActionId action, {String? gamepadId, double deadzone = 0.1, bool inverted = false}) → InputMapBuilder - Bind a gamepad axis to an action.
-
bindGamepadButton(
String buttonKey, ActionId action, {String? gamepadId}) → InputMapBuilder - Bind a gamepad button to an action.
-
bindKey(
LogicalKeyboardKey key, ActionId action) → InputMapBuilder - Bind a keyboard key to a button action.
-
bindKeyToAxis(
LogicalKeyboardKey key, ActionId action, {double value = 1.0}) → InputMapBuilder - Bind a keyboard key to an axis action (e.g., D for +X, A for -X).
-
bindLeftStick(
ActionId action, {double deadzone = 0.1, String? gamepadId}) → InputMapBuilder - Bind left analog stick to a Vector2 action.
-
bindMouseAxis(
MouseAxis axis, ActionId action, {double scale = 1.0}) → InputMapBuilder - Bind a mouse axis to an action.
-
bindMouseButton(
int button, ActionId action) → InputMapBuilder - Bind a mouse button to an action.
-
bindRightStick(
ActionId action, {double deadzone = 0.1, String? gamepadId}) → InputMapBuilder - Bind right analog stick to a Vector2 action.
-
bindWasd(
ActionId action) → InputMapBuilder - Bind WASD keys to a Vector2 action.
-
build(
) → InputMap - Build the InputMap.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
withActionType(
ActionId action, ActionType type) → InputMapBuilder - Explicitly set the action type.
-
withDeadzone(
ActionId action, double deadzone) → InputMapBuilder - Set deadzone for an action.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited