I wrote an algorithm that tries to find the perfect spot for each randomly chosen tetris-block. It calculates the ideal position according to a set of three rules:
1. The block has to be placed as low as possible.
2. The block has to fit as nicely as possible.
3. See if you can complete a row.
It turns out that giving (any) priority to row-completion, significantly decreases the stability of the program, resulting in an early game-over. The priority settings of this particlular run are 1/1.1/0 respectively.
In the future I might add a fourth rule that gives priority to preventing holes, which (I think) will drastically improve the performance.
Link to this comment:
All Comments (0)