JavaScript Joystick

I went to an arcade on Sunday and mashed buttons until my hands were sore. You just don’t get that same feeling playing Angry Birds.

But, if you want to build a classic action game and you’re handy with JavaScript, download the nippleJS library from Yoann Moinet.

nippleJS creates touch-controlled joysticks that track movement, direction, angle, and pressure (if you’ve got an iPhone6s). Set up a listener and use the positional data to trigger actions in your app/game.

nippleJS demo

Two killer features:

  1. You can position joysticks dynamically, so you don’t have to keep your finger in the same place.
  2. On multitouch devices, you can use two or more joysticks simultaneously.

Try this demo on your phone and get to hacking!

Comments :)
2017 Neal Shyam