I finally finished my version of Tetris. It's a Windows game. To play on your PC, download the installer below.
While teaching myself Microsoft DirectX, I fell into an issue that is best described as "invisible geometry". This is the unfortunate situation when lines aren't appearing when and where you expect them to. You've told DirectX to draw something, but you don't see it. The difficulties with getting this simple "two-faced triangle" to draw seemed to represent the difficulties with working with DirectX in general.
Tonight, I reached a good point with my coding of Tetris: I managed to get falling pieces that I could move horizontally. Some big things are missing: boundary detection, the creation of the "mound" (the pieces that collect at the bottom of the playing field), and the randomization of the pieces themselves.
I've been noodling with a Win32 version of Tetris, the ubiquitous "shape placing" game. I'm working in C++ using the Simple Directmedia Layer for my graphics. One of the interesting things in working out the game is the "shape" data. Below is the code for one my shapes, and the methods to "rotate" and "draw" it.