Conway's Game of Life (also known as Life) is a Cellular Automaton, discrete computational model, created by British Mathemetician John Horton Conway. Game of Life is a Zero Player Game, which means that the progression of the game only depends on the initial state set by the player.
Life is composed of a 2 dimensional infinite plane filled with cells. Each cell is represented as a square and is either alive (black) or dead (white). After each tick of gametime, every cell on the plane will determine how many of its neighbor cells are alive. The number of neighbor cells which are alive will then determine if the initial cell will live, die, or be born based on 4 pre-set rules.
It is important to note that all cells, regardless if they are alive or dead, check the 4 conditions above at the same time. At the start of the new tick, the status of all cells on the board updates at once.
For more information, check out this Wikipedia article. Additionally, check out the list of cool example videos below.
pip
package manager. This can be done with python -m pip install -r requirements.txt
.cd src
to move into the source code directory.python main.py
. This should bring up the starting screen of the game.When the game first starts up, you will load into the drawing screen. The drawing screen is where you can customize the starting state of the game.
Once you are ready to start the game, hit the green button. After you press the button, the game board will begin to change. Press the red button once you are ready to end the game, this will reset the board where you will be taken back to the drawing screen.
In the root directory, open plot.png
to view the population graph for the previous game after you hit the red button. See the example below.