• Home
  • About
    • Doğancan Algül photo

      Doğancan Algül

      Doğancan Algül's Personal Website

    • Learn More
    • Email
    • LinkedIn
    • Instagram
    • Github
  • Posts
    • All Posts
    • All Tags
  • Projects

Tetris with Processing

15 Mar 2019

Introduction

This is my first project. In the beginning, I started using Processing to visualize small game mechanics s.a. movement, jumping, and gravity. After a while, I decided to stop tinkering with Processing and create a game along the way.

I chose Tetris because I once read making Tetris, Breakout, Pacman, and Mario teach you the cores of video games. So I started with Tetris and made it in 3 days. It taught me a lot about the first bits.

Process

I didn’t know what is Javascript at the time. However, I didn’t spend any time learning the language. I just learned what I needed to do and used just that. That’s why the code is not perfect. But I used my OOP paradigm to create some object structure. First, I researched Tetris itself and learned that it has quite the lore. After my journey with tetrominos, I made my object structure as follows.

First, there is the Block which made a square on the screen: A block of a Tetromino

The second one is the tetrominos which is individual game pieces: Z Tetromino

Last but not the least, there is Game which controls every game aspect: A screenshot of the Tetris game

Result

Here is a video of one of my test playthroughs:

If you want to test it click here.

Do not hesitate to contact me on any matter!



processingjavascripttetris Share Tweet +1