Skip to content
Graphical implementation of the game of life through tkinter
Python
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
Conway.JPG
README.md
conway.py

README.md

Conways-Game-of-Life

Conway

Graphical implementation of the game of life with tkinter

Requires Python 3+ with numpy, tkinter, math and scipy

Background

I created this script mainly to improve my skills in tkinter and numpy. It utilizes tkinter to create a checkered canvas to run Conway's Game of Life. Live cells can be created by clicking and draging across the canvas. The code can also be stopped and started, and the time between updates changed via GUI controls.

To run the program

python conway.py
This will open the tkinter window. Look under other windows if it doesn't start at the top.

To begin the game of life

  • Select the starting cells by clicking or dragging the canvas
  • Click the start button

The height and width of the canvas, as well as the size of the cells can be changed by adding the optional arguments:

  • -h, --help to show help
  • -height or --height to change Canvas height
  • -width or --width to change Canvas width
  • -size or --size to change the size of the cells

Example: python conway.py --size 5 (this will make the size of the cells smaller -> default size = 10)

You can’t perform that action at this time.