slither-joystick-controller
Simple script to bind joystick controller to Slither mouse events
For now, only PS3 dualshock3 is supported.
Installation
npm i slither-joystick-controller
How to run
- go to the
node_modules/slither-joystick-controller
folder - run
node index.js
ornode index.js supported/controller/here
Supported Controllers
- ps3/dualshock3 (default)
- ps4/dualshock4
- snes/tomee
- snes/retrolink
- n64/retrolink
- logitech/rumblepad2
- logitech/dualaction
- logitech/gamepadf710
- microsoft/sidewinder-precision-2
These controllers are handled by node-gamepad. If you need to add another controller, see the Contributing Controllers of node-gamepad
.
How to use
Game pad action | Slither action |
---|---|
start | pause/unpause all the other actions. |
L3 | move mouse |
X | boost |
triangle | enter - use to start the game |
L2 | zoom out (require Slither plus extension) |
R2 | zoom in (require Slither plus extension) |
select | redefine center position. It can be useful when the game is not in full screen. Place your mouse on the snake head and press select to set the center. |
Libraries used in this project
- node-gamepad - for reading controller inputs
- robotjs - for firing mouse/keyboards events
- node-notifier - for displaying notifications