/tetris

Tetris using SDL2

Primary LanguageCGNU General Public License v3.0GPL-3.0

Tetris in C using SDL2

tetris screenshot

Builds and runs on MacOS and Web Assembly, but with a bit of effort should run elsewhere too.

Build it…​

Install the Xcode command line tools

xcode-select --install

Install emscripten.

Install SDL2 via Homebrew and run make

$ brew install sdl2 sdl2_image sdl2_ttf
$ make

Run the native build with ./build/tetris or the Web Assembly build using the index.html file through a web server. E.g.

$ python -m SimpleHTTPServer 8080