https://github.com/maxwellito/tetrispad
Use the Novation Launchpad to play Tetris
https://github.com/maxwellito/tetrispad
Last synced: 11 months ago
JSON representation
Use the Novation Launchpad to play Tetris
- Host: GitHub
- URL: https://github.com/maxwellito/tetrispad
- Owner: maxwellito
- License: mit
- Created: 2016-12-26T00:41:42.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2019-11-26T14:16:36.000Z (over 6 years ago)
- Last Synced: 2025-08-08T02:43:42.659Z (11 months ago)
- Language: JavaScript
- Homepage: https://maxwellito.github.io/tetrispad/
- Size: 69.3 KB
- Stars: 30
- Watchers: 3
- Forks: 3
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# TetrisPad
Plug your Novation Launchpad and [PLAY!](http://maxwellito.github.io/tetrispad/)
Single page app using the WebMIDI API to use the [Novation Launchpad](https://global.novationmusic.com/launch/launchpad-mini) as a screen for a Tetris.
## Controls
- `←`, `→`, `↓`: Move the current block
- `a`, `s`: Rotate the current block
- `spacebar`: Pause the game
## Code structure
The approach is quite classic, it's OOP.
- `Controller` class simulate the controller. It listens events from the keyboard to format and dispatch events to who needs it.
- `Launchpad` class wait for the Launchpad to be available on the MIDI API and allow to send/receive messages.
- `Grid` class is a wrapper to manages the LEDs of the Launchpad. The point of it is to facilitate the LEDs controls and reduce the amount of the messages to send the Launchpad.
- `Game` class contain the entire Tetris game logic.
## Contributors
Any crazy ideas are welcome (as long as your help :)
Please don't ask to setup a Webpack+Babel+WhatsoEver.. The Midi API is only accessible on modern browsers and these ones should be ES6 ready: feel again this pleasure to work on a repo without build system, it's so niiiice :)