I've completed a demo version of the project using Legecy OpenGL instead. This was a part of my Computer Graphics course project and with a tight deadline, I couldn't explore the modern OpenGL properly. Also, it was specially challenging to implement the whole game with only GL_POINT
. Please checkout demo/ directory, and compile and run the code to play with the project. I'll get back to modern OpenGL implementation if I get time later. Thank you.
A vibrant Tetris-inspired game where falling blocks and strategic power-ups collide, made entirely using OpenGL, C++, and GL_POINTS.
- Falling Blocks: Blocks continuously fall from the top of the grid.
- Player Controls: Use keyboard inputs to move blocks left, right, or rotate them.
- Line Clearing: Complete rows are detected and cleared, with the remaining blocks shifting down.
- Varied Blocks: Blocks come in different colors and shapes.
- Scoreboard: Tracks your score in real-time.
- Power-Ups and Traps: Randomized blocks with special effects to add variety.
- OpenGL: For rendering graphics.
- C++: Core game logic and structure.
- GLEW: For managing OpenGL extensions.
- GL_POINTS: Used exclusively for rendering all game visuals.
- A C++ compiler (e.g., GCC, Clang, or MSVC)
- OpenGL development libraries
- GLEW (OpenGL Extension Wrangler Library)
- Clone the repository:
git clone https://github.com/mahrjose/Tetrix.git cd Tetrix
- Compile and Run the code:
chmod +x run.sh ./run.sh
- Arrow Keys:
- Left: Move block left
- Right: Move block right
- Up: Rotate block
- Spacebar: Instantly drop the block
- Blocks will fall from the top of the grid.
- Use arrow keys to position and rotate the blocks.
- Complete rows to clear them and score points.
- Watch out for random power-ups and traps that change gameplay dynamics.
This project is licensed under the MIT License. See the LICENSE file for details.
- Inspired by the classic game Tetris.
- Built as a course project to explore the fundamentals of OpenGL and C++ programming.