Actionscript 3 Designer Toolkit

More design, less programming

Actionscript 3 Designer Toolkit header image 2

Programming Conway’s Game of Life

February 1st, 2010 · 1 Comment · AS3 Custom Classes, Apps

I first read about the study of self-replicating systems or Cellular Automata almost twenty years ago.  The great mathematician John von Neumann studied the problem during the 1940’s while working at Los Alamos.  In the 1970’s, another mathematician, John Conway devised the Game of Life, which was intended as a study of Cellular Automata, was then implemented on mainframes, at first, and then onto PC’s.

The basis of the game is a grid in which each cell can be either black (alive) or white (dead).  A pattern of black cells set by the user is tested against the following four rules:
1. if an alive (black) cell has only one or no live neighbors, the cell dies (white)
2. if an alive cell has more than 3 live neighbors, the cell dies
3. if an alive cell has either 2 or 3 neighbors, it lives to the next generation
4. if a dead (white) cell has exactly 3 live neighbors, it becomes alive (black)

The grid below follows the above rules. Click on a set of cells to make a pattern. You can than step through the rules one generation at a time with the Next button or have the program run it automatically with the Play button. If you are using the Next function, you can go back 1 generation with the Previous button. The Restart function returns the original pattern you input.

To learn more about Conway’s Gam of Life and get some interesting patterns go here.

The download includes the main program and 6 custom classes.

Download files: Conway.zip (65)

Post to Twitter

Tags: ···

One Comment so far ↓

  • polyGeek

    I love this stuff. I really need to find the time to mess with this stuff myself. I have all the books. Now I just need to buckle down and get it done. Thanks for reminding me.

Leave a Comment

Spam Protection by WP-SpamFree