Alert icon
We're changing our privacy policy. This stuff matters.  Learn more  Dismiss

Matlab playing Tetris

Loading...

Sign in or sign up now!
Alert icon
Upgrade to the latest Flash Player for improved playback performance. Upgrade now or more info.
580 views
Loading...
Alert icon
Sign in or sign up now!
Alert icon

Uploaded by on Sep 13, 2010

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.

Category:

Science & Technology

Tags:

License:

Standard YouTube License

  • likes, 0 dislikes

Link to this comment:

Share to:
see all

All Comments (0)

Sign In or Sign Up now to post a comment!
Loading...

Alert icon
0 / 00Unsaved Playlist Return to active list
    1. Your queue is empty. Add videos to your queue using this button:
      or sign in to load a different list.
    Loading...Loading...Saving...
    • Clear all videos from this list
    • Learn more