gamepads
0.1.15, released 12 days ago by flame-engine.org
A Flutter plugin to handle gamepad and joystick input across multiple platforms.
WASM-ready
What it does
Handles connected gamepads, tracking connection events, raw button/axis presses, and normalized input streams across Android, iOS, macOS, Linux, Windows, and Web. It also supports controller vibration and rumble effects.
AI-written summary of version 0.1.15, based on the package's README and metadata. Report an inaccuracy
Use it when
- You are building a game in Flutter that needs multi-platform controller support.
- You want consistent normalized gamepad buttons and axes layout across different operating systems.
Skip it when
- You only need basic touch and mouse pointer events.
- You require complex force feedback features beyond standard dual-motor rumble.
Strengths
- Supports multiple simultaneous gamepads with auto-connection listening.
- Normalized event stream abstracts platform-specific quirks and controller layouts.
- Cross-platform controller rumble/vibration support.
Weaknesses
- Android requires custom MainActivity boilerplate to forward input events.
- Vendor and product IDs are null on macOS and iOS.
- Linux requires SDL GameController DB mappings for unknown controllers.
Setup
- Kind
- Plugin (native code)
- Effort
- Medium
- Code generation
- No
- Direct dependencies
- 6
Requires adding platform-specific handling such as MainActivity boilerplate input dispatching on Android, and C++ desktop support / Windows SDK for Windows targets.
Gamepads.normalizedEvents.listen((event) {
if (event.button == GamepadButton.a && event.value != 0) {
print('A button pressed!');
}
});Works with
Packages commonly used together with gamepads: ones it builds on, ones built on it, and its own family.