/tetris-js

A clone of classic Tetris, in JavaScript, CSS, and HTML.

Primary LanguageJavaScript

Tetris Clone

Classic Tetris created in JavaScript and jQuery, for educational purposes.

By Robert Lee, 2019

Description

Classic Tetris, done in JavaScript.

Access App Directly on Github Pages

Click on the following link to access the app in your web browser directly:

https://bobbydwise1.github.io/tetris-js

Local Setup/Installation Requirements

  • Clone the application from Github.com by going to the terminal window command line and typing:

$ git clone https://github.com/bobbydwise1/tetris-js.git

  • After all the files have been copied, navigate to the project working directory. Open the index.html file in your web browser.

  • To begin the game, press the Spacebar. Also press Spacebar to reset the game.

  • You can also hard reset the application by refreshing your web browser tab.

  • To exit the application, close the web browser tab.

Controls

  • Keys:
    • SPACEBAR: Begin / reset game.
    • LEFT: Move piece left.
    • RIGHT: Move piece right.
    • DOWN: Soft drop - hold this key to speed up the falling rate.
    • Q: Rotate piece clockwise
    • W: Rotate piece counter-clockwise

Working Features

  • Clone of Classic Tetris in JavaScript.

Future Wishlist Features

  • High Score screen.
  • Option to change RNG for blocks between seeded, non-repeat, and random.
  • Music and sound effects.
  • Handheld controller support.

Known Bugs

  • Gravity timer doesn't speed up with each level.

Support and contact details

Technologies Used

  • JavaScript, jQuery, HTML, CSS, Bootstrap, Atom, VSCode, Google Fonts.

License

This application is Licensed under the MIT software License agreement. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

*The font "Press Start 2P" is from Google Fonts and is covered under SIL Open Font License (OFL). The DISCLAIMER for the SIL License reads in part:

THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE. *

Copyright (c) 2019 Robert Lee. This software is for educational purposes only, and constitutes fair use.