Inspiration

We saw neural networks learn how to play Mario, and we wondered whether or not we could apply it to other games.

What it does

The program analyzes the board, and evaluates the value of placing a block in a certain position by placing greater emphasis on the bottom rows.

How I built it

We downloaded a version of Tetris written in C++ with permission of the author. We then analyzed how the program stored data, fed the data into our algorithm, and then updated the board to process what the algorithm should do.

Challenges I ran into

We had a lot of trouble interpreting the data and feeding it into our algorithm. Particularly, we had trouble finding which piece was considered the central piece of each tetromino. Because of that, we had lots of trouble with segmentation faults, as we could not find the bounds of our board.

Accomplishments that I'm proud of

We are proud that we created an algorithm that can play Tetris for a large amount of time that makes intelligent decisions.

What I learned

We a lot of important information about how algorithms should weigh data, and how they use these considerations to make the best choice optimal. We also learned a lot about reading other people's code, and that we should make code easy to understand, as we had a lot of trouble reading the code for Tetris.

What's next for Table 19- Tetris Algorithm

Ideally, we would like our program to be able to play longer without failing. We also would like to use machine learning to optimize certain parameters which we assumed reasonable values for.

Built With

Share this project:

Updates