Joel Verhagen

a computer programming blog

Set v0.5


Currently I am working on a version of the popular card game Set for the computer. Here is a Wikipedia article about the rules and such. Basically I am moving what most people play with physical cards, onto the computer screen.

Current Version: v0.5

Last Updated: January 25, 2010


Basic Interface

  • Card Layout: All cards are display properly in the game window.
  • Card selection: Cards can be easily clicked on to be selected and deselected.
  • Set validation: Successfully and simply validating working sets. Thanks Peter!
  • Set finding: The current cards on the table can be searched for valid sets.
  • Keyboard shortcuts: All in-game interface has a keyboard shortcut associated with it. Here is the mapping.


  • When you first start-up the program... a main menu is displayed. There are three options. First is single player mode, the next is multiplayer mode (which has yet to be implemented), and lastly is an exit button.
  • When you choose single player mode... all twelve starting cards are displayed. If, perchance, the initial twelve starting cards contain no valid set, more cards are drawn until a valid set is available.
  • When you click on a card... the card is considered "selected" and is indicated as such by a red border.
  • When you click the "Set!" button... the three selected cards are verified to be a valid set and are removed. If the set was valid, the score is incremented by one.


Click here to download the zipped directory containing Set binaries. They only work on Windows systems. If you're not sure if this is what you should download to try it out, download this one.

If you're on another platform or would like to take a look under the hood, you can download the source here. I am currently working with Python 2.6.4, and Pygame 1.9.1 on Windows 7 64-bit. As long as you have recent versions of Python and Pygame installed, it should run okay.


  1. Download the package.
  2. Extract the .zip archive. Make sure to extract the entire archive or the program won't work right.
  3. Navigate to where the contents of the .zip archive were extracted and open up Set.exe.

Enjoy! If you have any problem getting it to run, feel free to contact me. Also, if you have any suggestions, I would love any input.


New to v0.5

  • Hot keys added to all in-game buttons.
  • Menuing system added.
  • Score counter added.
  • Removed unnecessary buttons.
  • Single player mode is pretty much complete.

New to v0.4

  • Click actions now fire when you release the mouse button.
  • Keyboard shortcuts for card selection are working.
  • Screen size has been adjusted to better fit content.